View previous topic :: View next topic |
Author |
Message |
kdvgent Guru
Joined: 29 Sep 2004 Posts: 352 Location: Belgium
|
Posted: Sat Aug 17, 2019 2:44 pm Post subject: SOLVED - Unable to remove file |
|
|
Quote: |
mycomputer /home/karel/data/OvdP Gent II/2019-2020 Jean van der Donk/201909 # ls -al
total 1024
drwxr-xr-x 2 karel users 0 Aug 17 16:23 .
drwxr-xr-x 2 karel users 0 Aug 17 16:22 ..
-rwxr-xr-x 1 karel users 52186 Aug 15 12:03 'OvdP GentII 201909 Uitnodiging.odt'
mycomputer /home/karel/data/OvdP Gent II/2019-2020/201909 # rm 'OvdP GentII 201909 Uitnodiging.odt'
rm: cannot remove 'OvdP GentII 201909 Uitnodiging.odt': No such file or directory
mycomputer /home/karel/data/OvdP Gent II/2019-2020/201909 # rm -f 'OvdP GentII 201909 Uitnodiging.odt'
mycomputer /home/karel/data/OvdP Gent II/2019-2020/201909 # ls -al
total 1024
drwxr-xr-x 2 karel users 0 Aug 17 16:23 .
drwxr-xr-x 2 karel users 0 Aug 17 16:22 ..
-rwxr-xr-x 1 karel users 52186 Aug 15 12:03 'OvdP GentII 201909 Uitnodiging.odt'
|
The file cannot be opened by Libreoffice writer neither. LibreOffice gives the same error message (file does not exist).
Any suggestion how I can get rid of that file? On the internet, I find all kind of suggestions on how deleting files with strange characters in the name but that is not my case.
Many thanks in advance.
Last edited by kdvgent on Sat Aug 17, 2019 4:35 pm; edited 1 time in total |
|
Back to top |
|
|
APolozov Apprentice
Joined: 28 Sep 2006 Posts: 189 Location: Voronezh, Russia
|
Posted: Sat Aug 17, 2019 3:05 pm Post subject: |
|
|
You can try to use filemask to delete or rename this file, rm *201909*odt for example.
And may be you want check filesystem, because filename look as well _________________ Excuse my bad English, I only study it. |
|
Back to top |
|
|
DaggyStyle Watchman
Joined: 22 Mar 2006 Posts: 5910
|
Posted: Sat Aug 17, 2019 3:15 pm Post subject: |
|
|
try this:
Code: | rm -rf OvdP\ GentII\ 201909\ Uitnodiging.odt |
_________________ Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein |
|
Back to top |
|
|
kdvgent Guru
Joined: 29 Sep 2004 Posts: 352 Location: Belgium
|
Posted: Sat Aug 17, 2019 3:25 pm Post subject: No luck |
|
|
Thanks for the suggestion but - no luck.
Quote: |
karel@mycomputer ~/data/OvdP Gent II/2019-2020/201909 $ rm -rf 'OvdP GentII 201909 Uitnodiging.odt'
karel@mycomputer ~/data/OvdP Gent II/2019-2020/201909 $ ls -al
total 1024
drwxr-xr-x 2 karel users 0 Aug 17 16:23 .
drwxr-xr-x 2 karel users 0 Aug 17 16:22 ..
-rwxr-xr-x 1 karel users 52186 Aug 15 12:03 'OvdP GentII 201909 Uitnodiging.odt'
karel@mycomputer ~/data/OvdP Gent II/2019-2020/201909 $
|
|
|
Back to top |
|
|
DaggyStyle Watchman
Joined: 22 Mar 2006 Posts: 5910
|
Posted: Sat Aug 17, 2019 4:03 pm Post subject: |
|
|
Code: | dagg@NCC-5001D ~ $ cd /tmp
dagg@NCC-5001D /tmp $ touch OvdP\ GentII\ 201909\ Uitnodiging.odt
dagg@NCC-5001D /tmp $ chmod a+x OvdP\ GentII\ 201909\ Uitnodiging.odt
dagg@NCC-5001D /tmp $ ll *.odt
-rwxr-xr-x 1 dagg dagg 0 Aug 17 19:03 'OvdP GentII 201909 Uitnodiging.odt'
dagg@NCC-5001D /tmp $ rm -rf OvdP\ GentII\ 201909\ Uitnodiging.odt
dagg@NCC-5001D /tmp $ ll *.odt
ls: cannot access '*.odt': No such file or directory |
_________________ Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein |
|
Back to top |
|
|
kdvgent Guru
Joined: 29 Sep 2004 Posts: 352 Location: Belgium
|
Posted: Sat Aug 17, 2019 4:17 pm Post subject: Still no luck |
|
|
Quote: |
karel@mycomputer ~/data/OvdP Gent II/2019-2020 Jean van der Donk/201909 $ touch 'OvdP GentII 201909 Uitnodiging.odt'
touch: cannot touch 'OvdP GentII 201909 Uitnodiging.odt': No such file or directory
karel@mycomputer ~/data/OvdP Gent II/2019-2020 Jean van der Donk/201909 $ chmod a+x 'OvdP GentII 201909 Uitnodiging.odt'
chmod: cannot access 'OvdP GentII 201909 Uitnodiging.odt': No such file or directory
karel@mycomputer ~/data/OvdP Gent II/2019-2020 Jean van der Donk/201909 $ ls -al
total 1024
drwxr-xr-x 2 karel users 0 Aug 17 16:23 .
drwxr-xr-x 2 karel users 0 Aug 17 16:22 ..
-rwxr-xr-x 1 karel users 52186 Aug 15 12:03 'OvdP GentII 201909 Uitnodiging.odt'
karel@mycomputer ~/data/OvdP Gent II/2019-2020 Jean van der Donk/201909 $ rm -rf 'OvdP GentII 201909 Uitnodiging.odt'
karel@mycomputer ~/data/OvdP Gent II/2019-2020 Jean van der Donk/201909 $ ls -al
total 1024
drwxr-xr-x 2 karel users 0 Aug 17 16:23 .
drwxr-xr-x 2 karel users 0 Aug 17 16:22 ..
-rwxr-xr-x 1 karel users 52186 Aug 15 12:03 'OvdP GentII 201909 Uitnodiging.odt'
|
To my understanding, the file does not exist anymore on disk but is still listed in the directory. Do not know how this is possible.
But again, thanks for your suggestions |
|
Back to top |
|
|
kdvgent Guru
Joined: 29 Sep 2004 Posts: 352 Location: Belgium
|
Posted: Sat Aug 17, 2019 4:29 pm Post subject: Additional info |
|
|
I assume I should give the following information:
The file is physically on a remote zfs filesystem (FreeNAS).
The zfs filesystem is reported healthy. |
|
Back to top |
|
|
kdvgent Guru
Joined: 29 Sep 2004 Posts: 352 Location: Belgium
|
Posted: Sat Aug 17, 2019 4:36 pm Post subject: Solution |
|
|
Once I remembered that the file was on a zfs filesystem on FreeNAS, I could delete the file by logging in into the FreeNAS server via ssh and delete the file there. |
|
Back to top |
|
|
DaggyStyle Watchman
Joined: 22 Mar 2006 Posts: 5910
|
Posted: Sat Aug 17, 2019 5:40 pm Post subject: |
|
|
glad it worked out for you but just to point out, you've never tried my suggestion. _________________ Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein |
|
Back to top |
|
|
|