LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 12-03-2011, 02:48 PM   #16
passegua
LQ Newbie
 
Registered: Nov 2011
Location: Barcelona
Distribution: Ubuntu 11.10
Posts: 19

Original Poster
Rep: Reputation: Disabled

Quote:
Originally Posted by segmentation_fault View Post
Could the "input/output error" indicate a corruption in filesystem or a bad disk?
may be.

Any solution?

I've read something about fsck, fdisk, debugfs but I don't know how use those command, do you?

Thanks.

Last edited by passegua; 12-03-2011 at 03:24 PM.
 
Old 12-03-2011, 03:13 PM   #17
segmentation_fault
Member
 
Registered: Sep 2008
Location: Ioannina, Greece
Distribution: Gentoo
Posts: 332

Rep: Reputation: 54
To run fsck (File System ChecK) on your root (/) partition, first of all you need to mount in read-only. In order to do that, I first enter runlevel 1. Type on a terminal
Code:
# telinit 1
as root, or using sudo. Then login as root, if necessary and mount your root partition read-only:
Code:
# mount / -o remount,ro
Next step, force a fsck on that (assuming your root partition is sda1):
Code:
# fsck -f -v /dev/sda1
When the check is done, mount it read-write and either reboot or enter your previous runlevel with telinit:
Code:
# mount / -o remount,rw
# shutdown -r now
 
Old 12-03-2011, 03:27 PM   #18
passegua
LQ Newbie
 
Registered: Nov 2011
Location: Barcelona
Distribution: Ubuntu 11.10
Posts: 19

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by segmentation_fault View Post
To run fsck (File System ChecK) on your root (/) partition, first of all you need to mount in read-only. In order to do that, I first enter runlevel 1. Type on a terminal
Code:
# telinit 1
as root, or using sudo. Then login as root, if necessary and mount your root partition read-only:
Code:
# mount / -o remount,ro
Next step, force a fsck on that (assuming your root partition is sda1):
Code:
# fsck -f -v /dev/sda1
When the check is done, mount it read-write and either reboot or enter your previous runlevel with telinit:
Code:
# mount / -o remount,rw
# shutdown -r now
Thank you very much for your help, but I suppose being too newbie to understand all those "mount" "unomunt" stuff.

For instance, how could I know "my root partition is sda1" ?

If I call mount:

Code:
 mount
/cow on / type overlayfs (rw,commit=0,commit=0)
proc on /proc type proc (rw,noexec,nosuid,nodev)
sysfs on /sys type sysfs (rw,noexec,nosuid,nodev)
fusectl on /sys/fs/fuse/connections type fusectl (rw)
udev on /dev type devtmpfs (rw,mode=0755)
devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
tmpfs on /run type tmpfs (rw,noexec,nosuid,size=10%,mode=0755)
/dev/sdb1 on /cdrom type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=cp437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/loop0 on /rofs type squashfs (ro,noatime)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev)
none on /run/lock type tmpfs (rw,noexec,nosuid,nodev,size=5242880)
none on /run/shm type tmpfs (rw,nosuid,nodev)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/passegua/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=passegua)

I do not understand where is root mounted.

I try this:

Code:
~$ df -h
File system            Dim. Usati Disp. Uso% Mounted on
/cow                  2,0G  1,6G  299M  85% /
udev                  494M  4,0K  494M   1% /dev
tmpfs                 201M  812K  200M   1% /run
/dev/sdb1             7,9G  2,7G  5,3G  34% /cdrom
/dev/loop0            668M  668M     0 100% /rofs
tmpfs                 501M  8,0K  501M   1% /tmp
none                  5,0M     0  5,0M   0% /run/lock
none                  501M  116K  501M   1% /run/shm
So I suppose my root partition is /cow isn't it?

Thanks.

Last edited by passegua; 12-03-2011 at 03:53 PM.
 
Old 12-03-2011, 04:22 PM   #19
passegua
LQ Newbie
 
Registered: Nov 2011
Location: Barcelona
Distribution: Ubuntu 11.10
Posts: 19

Original Poster
Rep: Reputation: Disabled
I tried.

telinit 1

and then

mount / -o remount,ro

then

fsck -f -v /cow

I got error: fsck.ext2 in /cow not exist
or something like this since I was in terminal out of ubuntu could not copy the output.

I tried also

fsck -f -v /

and got: fsck.overlayfs not exist
 
Old 12-03-2011, 04:38 PM   #20
yancek
Senior Member
 
Registered: Apr 2008
Distribution: PCLinux, Ubuntu, Slackware
Posts: 4,959

Rep: Reputation: 785Reputation: 785Reputation: 785Reputation: 785Reputation: 785Reputation: 785Reputation: 785
Open a terminal and enter this: gksu nautilus or gksudo nautilus. Navigate to your Trash folder and open the files and info folders separately or whatever you want to delete. You can Select All or select individually to highlight files. When you have them highlighted, hold down the Shift and Delete keys and you will be prompted and asked if you want to delete whatever files are highlighted. I've done this on Ubuntu 10.10 and 11.10 and I think I found this solution on the Ubuntu forums after trying several of the standard methods suggested above which didn't work either??
 
Old 12-03-2011, 05:37 PM   #21
passegua
LQ Newbie
 
Registered: Nov 2011
Location: Barcelona
Distribution: Ubuntu 11.10
Posts: 19

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by yancek View Post
Open a terminal and enter this: gksu nautilus or gksudo nautilus. Navigate to your Trash folder and open the files and info folders separately or whatever you want to delete. You can Select All or select individually to highlight files. When you have them highlighted, hold down the Shift and Delete keys and you will be prompted and asked if you want to delete whatever files are highlighted. I've done this on Ubuntu 10.10 and 11.10 and I think I found this solution on the Ubuntu forums after trying several of the standard methods suggested above which didn't work either??
Impossible.

This is the error message:

Error finding file stat "/root/.local/share/Trash/files/danieluvi/.mozilla/firefox/irndj1vf.default/Cache/7/9A/85658d01": input/output error
 
Old 12-04-2011, 06:04 AM   #22
nigelc
Member
 
Registered: Oct 2004
Location: Sydney, Australia
Distribution: Mageia 4
Posts: 304
Blog Entries: 4

Rep: Reputation: 52
Hello,
Maybe the file is in use. Go into single user mode, then try it. init 1 will goto into single user mode.

cheers
 
Old 12-04-2011, 08:46 AM   #23
passegua
LQ Newbie
 
Registered: Nov 2011
Location: Barcelona
Distribution: Ubuntu 11.10
Posts: 19

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by nigelc View Post
Hello,
Maybe the file is in use. Go into single user mode, then try it. init 1 will goto into single user mode.

cheers
Indeed I thought the same as in windows some times you cannot delete a file in use.
But I restarted as single user and the input-output error is still there, impossible remove.

Well ubuntu is keeping well hidden its secrets :-)
 
Old 12-04-2011, 01:43 PM   #24
segmentation_fault
Member
 
Registered: Sep 2008
Location: Ioannina, Greece
Distribution: Gentoo
Posts: 332

Rep: Reputation: 54
Indeed your root partition is /cow, although I would expect /dev/something. Maybe
Code:
# fdisk -l
give some more light, but if it realy is an overlayfs I don't know if it can be checked. In fact, I don't even know what is overlayfs.
 
Old 12-04-2011, 06:00 PM   #25
Brains
Member
 
Registered: Apr 2009
Distribution: Debian testing
Posts: 258

Rep: Reputation: 42
Another suggestion.
I just ran another test and put a photo called "Wolf.jpg" in the trash through my file manager dolphin. Based on the test I did from command line posted below, I had to specify the name of the file, using a wild card did not work.
Code:
jo@jo:~$ sudo rm /root/.local/share/Trash/files/*
[sudo] password for jo: 
rm: cannot remove `/root/.local/share/Trash/files/*': No such file or directory
jo@jo:~$ sudo rm /root/.local/share/Trash/files/Wolf.jpg
jo@jo:~$
I have had similar issues in Windows, where I could not delete certain files, but rebooting into Linux or Mac OSX and deleting from there most often would do the trick. There was the odd time where I could not do it from any OS, probably because there was an error in Windows MFT where it still reported an existing file that actually did not exist anymore. If this is your case, even if the file does not exist, the space will not be marked as free space and cannot be written to.

Last edited by Brains; 12-04-2011 at 06:17 PM. Reason: Wrong thread, having iceweasel issues, woops, it was the right tread.
 
Old 12-04-2011, 07:39 PM   #26
VDP76
Member
 
Registered: Apr 2010
Location: Bayreuth, Germany
Distribution: CrunchBang Linux (#!)
Posts: 111

Rep: Reputation: 19
Quote:
Originally Posted by passegua View Post
Since I installed Ubuntu 11.10 on a 8GB pendrive
Since your Ubuntu is on a pendrive, have you considered the idea of just mounting the disk into another OS to delete those files!?!?
it's not an "elegant solution", but it might be a workaround...

good luck!
 
Old 12-06-2011, 08:01 AM   #27
amilo
Member
 
Registered: Oct 2011
Location: Nederland
Distribution: Debian, Centos, Ubuntu
Posts: 65

Rep: Reputation: Disabled
what is the answer of lsattr 'filename'
 
  


Reply

Tags
delete, trash, usb boot


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Cannot empty Gnome desktop Trash folder rich16870 Linux - Desktop 13 11-27-2008 12:08 AM
How to open the trash folder and empty the trash in command line cmx08 Linux - Newbie 5 08-29-2008 09:15 AM
Move to trash works beautifully, but empty trash .. different story. kd5eax Mandriva 2 12-04-2007 02:52 PM
Evolution: Can't Empty Trash; Summary and Folder Mismatch snickdog Linux - Software 1 03-17-2007 02:00 PM
Evolution will not empty trash folder azebuski Linux - Software 0 05-25-2004 11:40 AM


All times are GMT -5. The time now is 08:43 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration