From: Goswin v. B. <gos...@we...> - 2008-08-22 06:20:33
|
"Christos I." <ssj...@ya...> writes: > I already did. I gave full permissions to the root and also set the user and > group to be the one currently logged in. when i mount the filesystem i > ckeck the permissions through the terminal and everything seems to be ok. > the user is myself and have full access rights. But still I can neither > create directories or files. I can delete but net create Not just permission. You need to have one of S_IFMT 0170000 bit mask for the file type bit fields S_IFSOCK 0140000 socket S_IFLNK 0120000 symbolic link S_IFREG 0100000 regular file S_IFBLK 0060000 block device S_IFDIR 0040000 directory S_IFCHR 0020000 character device S_IFIFO 0010000 FIFO (man 2 stat) > Miklos Szeredi wrote: >> >> On Sun, 3 Aug 2008, Christos I. wrote: >>> Hi. I'm having some problems creating my own filesystem. What I am trying >>> to >>> do is to create directories and files stored in text files. I jave some >>> text >>> files containing paths to the different folders and files and these show >>> up >>> in the filesystem. >>> >>> I followed the Hellow World example here >>> http://fuse.sourceforge.net/wiki/index.php/Hello World and I managed to >>> create the filesystem as described. However now I want to be able to >>> create >>> and delete directories. I created the functions to remove the directories >>> from the text files but I have a problem implementing them in the >>> filesystem. The rmdir function works ok but the mkdir and create >>> functions >>> do not work. I am getting the following error when trying to create a new >>> directory or file: >>> mkdir: cannot create directory `directory': Input/output error. >> >> You need to return valid attributes (notably st_mode) in getattr() for >> the newly created directory. >> >> Miklos MfG Goswin |