probable ext4 filesystem error?

On her openSUSE 12.2 system running KDE4, my sister created a subdirectory, from the command line, in her home directory, then found it unusable. When she tried to look at it with dolphin it did not show up at all. From the command line, ll (ls -l) shows the following:
skywalker:~ $ ll ~lynn
ls: cannot access /home/lynn/kindle: Permission denied
total 72K
:
drwxr-xr-x 10 lynn users 4.0K Mar 14 2010 DosGames
d??? ? ? ? ? ? kindle
drwxr-xr-x 2 lynn users 4.0K Jan 9 20:55 Kindle
:
$

She tried to remove it (both from her account and from root), and got this:

skywalker:~ # rmdir ~lynn/kindle
rmdir: failed to remove ‘/home/lynn/kindle’: Device or resource busy
$

She was able to create _another_ directory with the same name with dolphin, after which ll shows:

skywalker:~ $ ll ~lynn
ls: cannot access /home/lynn/kindle: Permission denied
total 72K
:
drwxr-xr-x 10 lynn users 4.0K Mar 14 2010 DosGames
d??? ? ? ? ? ? kindle
drwxr-xr-x 2 lynn users 4.0K Jan 9 20:55 Kindle
:
$

I'm guessing that the filesystem is corrupted, but I thought I'd better run it past the experts to see what you think.

Can this be fixed by running fsck from a bootable CD?

Leslie

Please show output of “grep kindle /proc/mounts”. In tags CODE, please :slight_smile:


$grep kindle /proc/mounts
jmtpfs /home/lynn/kindle fuse.jmtpfs rw,nosuid,nodev,relatime,user_id=1000,group_id=100 0 0

On 01/10/2013 07:06 AM, jlturriff wrote:
> my sister created a
> subdirectory, from the command line, in her home directory,

first: how? that is, what command line string did she type in?

she should be able to open a CLI and press the up arrow until she comes
to the command she used…

second: what is she trying to do? well, i kinda sounds like (maybe) she
has a Kindle that she wants to connect to her computer and . . . and
what? mount it and move files back and forth…

as for the existing ‘kindle’: VERY strange!! you might try (read the
caveat in my sig), while logged into the DE as a regular user use the
menu to open an instance of Applications > System > File Manager > File
Manager - Superuser Mode (which is just Dolphin running with root
powers…then see if you can right-click on /home/home/lynn/kindle and
select Delete…

and, comments on some of the CLI in your post:

“skywalker:~ $ ll ~lynn” should be expected to fail, as skywalker should
not have access to lynn’s home

“skywalker:~ # rmdir ~lynn/kindle” did you try rm (instead of rmdir)?
maybe the system sees it as a file named kindle, rather than a
directory?? what happens if you try


# rmdir ~/lynn/kindle/

(note the addition of two more /s)

“skywalker:~ $ ll ~lynn” again, skywalker should expect to see
“Permission denied” in Lynn’s home

hmmmmm…interesting…
maybe, while logged into KDE as a normal user, open a terminal and issue
“su -” (do not forget the dash), give the root password, then cd to
/home/lynn/ and issue


ls k*

it MIGHT be that only the malformed ‘kendle’ is seen (and NO other file
or directory…or maybe this


ls k?????

returns ONLY the broken ‘kendle’…if so then try these, in a root
terminal, one at a time


# rmdir ~/lynn/k?????/   (or "/k*" as appropriate)
# rm ~/lynn/k?????


dd http://tinyurl.com/DD-Caveat

Well, /home/lynn/kindle is mount point for some (pseudo-)filesystem. It has nothing to do with ext4. I presume that this filesystem is used to access kindle? and right now aceess is not possible for whatever reason. So there is nothing to actually worry abut and there is no ext4 corruption.

While native Linux filesystems like ext4 distinguish between files/folders (etc.)
that have names, which differ only by uppercase/lowercase of the letters,
windows filesystems like NTFS or FAT don’t.

Whatever your sister did, it might be better not to create a folder ‘Kindle’ (with uppercase ‘K’)
in folder ‘~lynn’.
Is she sure which one she created?

Please note the difference:


knurpht@laptop:~> mkdir ~test
knurpht@laptop:~> ls -ld ~test
drwxr-xr-x 2 knurpht users 4096 10 jan 12:44 ~test
knurpht@laptop:~> mkdir ~/test
knurpht@laptop:~> ls -ld ~/test
drwxr-xr-x 2 knurpht users 4096 10 jan 12:45 /home/knurpht/test

So, your sister created a folder called " ~lynn " in the folder where she was at execution of the command. The special char " ~ " means nothing when not followed by a " / ", if the " / " isn’t there it’s just a part of the folder- or filename you create.

Knurpht wrote:
> Please note the difference:
>
> Code:
> --------------------
>
> knurpht@laptop:~> mkdir ~test
> knurpht@laptop:~> ls -ld ~test
> drwxr-xr-x 2 knurpht users 4096 10 jan 12:44 ~test
> knurpht@laptop:~> mkdir ~/test
> knurpht@laptop:~> ls -ld ~/test
> drwxr-xr-x 2 knurpht users 4096 10 jan 12:45 /home/knurpht/test
>
> --------------------
>
>
> So, your sister created a folder called " ~lynn " in the folder where
> she was at execution of the command. The special char " ~ " means
> nothing when not followed by a " / ", if the " / " isn’t there it’s just
> a part of the folder- or filename you create.

That’s not quite complete. ~lynn means lynn’s home directory if there is
a user called lynn. ls ~lynn will list the contents of /home/lynn

I have no idea about whatever obscure corner cases there are :slight_smile:

On 01/10/2013 12:56 PM, Knurpht wrote:
> The special char " ~ " means > nothing when not followed by a " / "

SUPER!! i just keep learnin’
thx


dd

>> The special char " ~ " means > nothing when not followed by a " / "
>
> SUPER!! i just keep learnin’

Just be sure to read Dave Howarth’s correction, because if you learn this
(what Knurpht wrote) it is wrong. It is pretty common to do something
like ~/fileInMyUserHomeDir and less common to do something like
~user/fileInUserHomeDir but both are valid as long as ‘user’ exists in the
latter case. If ‘user’ does not exist in the latter case then it treats
‘~’ literally and creates the file in the current directory as if ~user
had been specified (escaping the tilde).

Good luck.

On 01/10/2013 05:08 PM, ab wrote:
> escaping the tilde

ah…thx.


dd

thanks for the correction, learned something.

She used


mkdir kindle

at the command line.

second: what is she trying to do? well, i kinda sounds like (maybe) she
has a Kindle that she wants to connect to her computer and . . . and
what? mount it and move files back and forth…

as for the existing ‘kindle’: VERY strange!! you might try (read the
caveat in my sig), while logged into the DE as a regular user use the
menu to open an instance of Applications > System > File Manager > File
Manager - Superuser Mode (which is just Dolphin running with root
powers…then see if you can right-click on /home/home/lynn/kindle and
select Delete…

and, comments on some of the CLI in your post:

“skywalker:~ $ ll ~lynn” should be expected to fail, as skywalker should
not have access to lynn’s home

Perhaps I should have stripped off the bash prompt which is


skywalker:~ 

“skywalker:~ # rmdir ~lynn/kindle” did you try rm (instead of rmdir)?
maybe the system sees it as a file named kindle, rather than a
directory??

Might work, but from the messages it appears that the resource is locked, so probably not.

what happens if you try

rmdir ~/lynn/kindle/

(note the addition of two more /s)

That would be a different path, so no.

“skywalker:~ $ ll ~lynn” again, skywalker should expect to see
“Permission denied” in Lynn’s home

hmmmmm…interesting…
maybe, while logged into KDE as a normal user, open a terminal and issue
“su -” (do not forget the dash), give the root password, then cd to
/home/lynn/ and issue

ls k*

We tried that, too.

it MIGHT be that only the malformed ‘kendle’ is seen (and NO other file
or directory…or maybe this

ls k???

returns ONLY the broken ‘kendle’…if so then try these, in a root
terminal, one at a time

rmdir ~/lynn/k???/ (or “/k*” as appropriate)

rm ~/lynn/k???


dd DD Caveat

I will have her try this asap. I think that you have put me on the right track with this. Doing


umount ~lynn/kindle

should free it up, if that is the case.
(This is the first time I have seen that sort of response to the ls command; thus my confusion.)

Okay. After rebooting the system the directory looks like we would expect, and is accessible; so you are quite right that this is not a filesystem corruption, but simply a mounted fuse filesystem. We will now try to figure out usage of the mounted filesystem.

Thanks for putting us straight here.

Leslie