Page 1 of 1
How to delete files? Files with spaces in their na [Solved]
Posted: 27 Sep 2014, 16:01
by Ed_P
Ok, I had 2 .wav files with a space in their names. So I renamed them. I had a shortcut from a module that i don't use that had a space in it's name so I deleted it.
I reboot, the shortcut is back and so too are the .wav files with the space in their names.
OK, been here before, a problem with .wh. files. I reboot to Always Fresh mode, manually delete the 3 .wh. files associated with the 3 files. I reboot to my normal changes=EXIT mode and t h e y a r e a l l b a c k !!!!
I'm running 3.0.1 which I thought resolved the .wh. file problem so what to do now? Will the Porteus save file manager's recover a savefile option fix the problem? Will deleting all the save.dat file's .wh. files fix the problem? (I have LOTS of FireFox and Java .wh. files which I don't care about and don't seem to be causing any problems.)
Re: How to delete files? Files with spaces in their names.
Posted: 27 Sep 2014, 18:20
by THX2006
Hello Ed_P
New to Porteus but, Any chance you would need to do it from root ? Maybe rename and leave off the file extension and then use the shred command ?
I'm bad at leaving spaces where they don't belong but haven't had your problem yet. I need to stop doing that I guess.
Re: How to delete files? Files with spaces in their names.
Posted: 27 Sep 2014, 21:01
by brokenman
How to delete files? Files with spaces in their names
rm "/tmp/my file with spaces.txt"
Re: How to delete files? Files with spaces in their names.
Posted: 27 Sep 2014, 21:38
by Ed_P
Code: Select all
guest@porteus:~$ cd Sounds
guest@porteus:~/Sounds$ ls
Alien_Siren-KevanGC-610357990.wav
Busy\ Signal-SoundBible.com-1695161320.wav
Busy_Signal-SoundBible.com-1695161320.wav
Rooster\ Crowing-SoundBible.com-43612401.wav
Rooster_Crowing-SoundBible.com-43612401.wav
guest@porteus:~/Sounds$ rm "Busy\ Signal-SoundBible.com-1695161320.wav"
rm: cannot remove ‘Busy\\ Signal-SoundBible.com-1695161320.wav’: No such file or directory
guest@porteus:~/Sounds$ rm "Busy Signal-SoundBible.com-1695161320.wav"
guest@porteus:~/Sounds$ rm "Rooster Crowing-SoundBible.com-43612401.wav"
guest@porteus:~/Sounds$ ls
Alien_Siren-KevanGC-610357990.wav
Busy_Signal-SoundBible.com-1695161320.wav
Rooster_Crowing-SoundBible.com-43612401.wav
guest@porteus:~/Sounds$
And no error msgs indicating I need root to access them.
-- rebooted --
Code: Select all
guest@porteus:~$ cd Sounds
guest@porteus:~/Sounds$ ls
Alien_Siren-KevanGC-610357990.wav
Busy\ Signal-SoundBible.com-1695161320.wav
Busy_Signal-SoundBible.com-1695161320.wav
Rooster\ Crowing-SoundBible.com-43612401.wav
Rooster_Crowing-SoundBible.com-43612401.wav
guest@porteus:~/Sounds$
Didn't work.
=update=
Always Fresh mode
Code: Select all
guest@porteus:~$ rm /mnt/loop/home/guest/Sounds/.wh.*
rm: remove write-protected regular empty file ‘/mnt/loop/home/guest/Sounds/.wh.Busy Signal-SoundBible.com-1695161320.wav’? yes
rm: remove write-protected regular empty file ‘/mnt/loop/home/guest/Sounds/.wh.Rooster Crowing-SoundBible.com-43612401.wav’? yes
guest@porteus:~$ rm /mnt/loop/home/guest/.wh.PlayOnLinux*
rm: remove write-protected regular empty file ‘/mnt/loop/home/guest/.wh.PlayOnLinux's virtual drives’? yes
guest@porteus:~$ uloop
Password:
/mnt/loop has been unmounted
guest@porteus:~$
== rebooted ==
Code: Select all
guest@porteus:~$ ls Sounds
Alien_Siren-KevanGC-610357990.wav
Busy\ Signal-SoundBible.com-1695161320.wav
Busy_Signal-SoundBible.com-1695161320.wav
Rooster\ Crowing-SoundBible.com-43612401.wav
Rooster_Crowing-SoundBible.com-43612401.wav
guest@porteus:~$
I haven't had to rebuild my save.dat file in a long time but I don't see any other fix at this point. Something is broken somewhere.
Re: How to delete files? Files with spaces in their names.
Posted: 27 Sep 2014, 22:51
by Slaxmax
you need use chattr -i before remove file.
example
Code: Select all
root@porteus:/mnt/sda2# chattr -i /mnt/sda2/index.html
root@porteus:/mnt/sda2# rm /mnt/sda2/index.html
Re: How to delete files? Files with spaces in their names.
Posted: 28 Sep 2014, 05:08
by Ed_P
File Properties for the .wav files shows:
Owner: guest
Group: guest
Owner: Read, Write
Group: Read
Other: Read
However for the PlayOnLinux file it shows:
Owner: root
Group: root
Owner: Read, Write, Execute
Group: Read, Write, Execute
Other: Read, Write, Execute
These latter properties are a bit of a shock!! Why don't I receive Access Denied errors when I try to delete it???
Code: Select all
guest@porteus:~$ ls Sounds
Alien_Siren-KevanGC-610357990.wav
Busy\ Signal-SoundBible.com-1695161320.wav
Busy_Signal-SoundBible.com-1695161320.wav
Rooster\ Crowing-SoundBible.com-43612401.wav
Rooster_Crowing-SoundBible.com-43612401.wav
guest@porteus:~$ chattr -i "Sounds/Busy Signal-SoundBible.com-1695161320.wav"
chattr: Inappropriate ioctl for device while reading flags on Sounds/Busy Signal-SoundBible.com-1695161320.wav
guest@porteus:~$ rm "Sounds/Busy Signal-SoundBible.com-1695161320.wav"
guest@porteus:~$ ls Sounds
Alien_Siren-KevanGC-610357990.wav
Busy_Signal-SoundBible.com-1695161320.wav
Rooster\ Crowing-SoundBible.com-43612401.wav
Rooster_Crowing-SoundBible.com-43612401.wav
guest@porteus:~$ su
Password:
root@porteus:/home/guest# rm "Sounds/Rooster Crowing-SoundBible.com-43612401.wav"
root@porteus:/home/guest# ls Sounds
Alien_Siren-KevanGC-610357990.wav
Busy_Signal-SoundBible.com-1695161320.wav
Rooster_Crowing-SoundBible.com-43612401.wav
root@porteus:/home/guest# rm PlayOnLinux*
root@porteus:/home/guest#
== reboot ==
Code: Select all
guest@porteus:~$ ls Sounds
Alien_Siren-KevanGC-610357990.wav
Busy\ Signal-SoundBible.com-1695161320.wav
Busy_Signal-SoundBible.com-1695161320.wav
Rooster\ Crowing-SoundBible.com-43612401.wav
Rooster_Crowing-SoundBible.com-43612401.wav
guest@porteus:~$
The PlayOnLinux one also.
Thanks for the suggestions guys.
Re: How to delete files? Files with spaces in their names.
Posted: 28 Sep 2014, 23:21
by Ed_P
brokenman wrote:How to delete files? Files with spaces in their names
rm "/tmp/my file with spaces.txt"
rm /tmp/my*
works also.
But if they are zombie files they keep coming back.
Re: How to delete files? Files with spaces in their names.
Posted: 05 Oct 2014, 04:45
by Ed_P
Built a new save.dat file.
Re: How to delete files? Files with spaces in their na [Sol
Posted: 15 Oct 2014, 04:29
by Ed_P
Dumb, DUMB,
DUMB!!!
The actual deleted files are in the save.dat file, not just their associated .wh. files.
To delete them once and for all one must delete the .wh. file
AND the actual file from the save.dat file.
Good grief, how long did it take to figure this out?