Saved a .zip file with a folder's name: is the folder lost?

Hi, I’m new with openSUSE (Tumbleweed) and have this issue: from Firefox saved a ZIP file on a folder but clicked accidentally in another folder before saving, so apparently the ZIP file took the name of that folder and got saved instead of the folder: now I can’t access the files and folders inside that folder. It’s like if the ZIP file replaced the folder but losing its content in the process… I can see the names of the files inside the folder but I can’t open them: the Properties (PCManFM) say: “inode/x-corrupted type (inode/x-corrupted)”, and from terminal cd foldername replies “Permission denied”.
Meanwhile, df shows me that disk space keeps the same (as if the content of the folder is still occupying storage space).
Can someone explain what happened or how to reverse it (if possible)?
Thanks a lot in advance, let me know if there’s more information I should provide and sorry for the inconvenience.
Best regards!

Are you using LXQt as the DE then?

Does sudo cd foldername and entering the root password work?

1 Like

Hi, thanks a lot for your help.

No, just IceWM.

sudo cd doesn’t work, it says:

sudo: cd: command not found
sudo: "cd" is a shell built-in command, it cannot be run directly.
sudo: the -s option may be used to run a privileged shell.
sudo: the -D option may be used to run a command in a specific directory.

But sudo su and then cd foldername works fine. I can navigate the internal folders and see the files and nano text files (see the content).

Please show
ls -l foldername

If it is not a to big structure, better
ls -lR foldername

It would also be good to know, where this affected folder is located. If it is in some root owned path, it is normal that you can’t access it as normal user. If it is located in the user owned path, something is wrong for sure.

1 Like

Seems like a permission issue. Probably a missmatch between the content permissions and/or the folder permissions.

To elaborate follow the commands hui sent.

1 Like

Thanks again.

The affected folder is located in the user owned path: /home/user/Downloads

user@localhost:~/Downloads> ls -lR foldername/
foldername/:
ls: cannot access 'foldername/5EmWdWb_.zip.part': Permission denied
ls: cannot access 'foldername/Belen (2025) [1080p] [WEBRip] [5.1] [YTS.MX]': Permission denied
ls: cannot access 'foldername/VISTAS': Permission denied
ls: cannot access 'foldername/Ju-on Black Ghost (2009) [1080p] [BluRay] [YTS.MX]': Permission denied
ls: cannot access 'foldername/Crimes Of The Future (1970) [1080p] [BluRay] [YTS.MX]': Permission denied
ls: cannot access 'foldername/Going In Style (1979) [1080p] [WEBRip] [YTS.MX]': Permission denied
ls: cannot access 'foldername/Going In Style (2017) [1080p] [YTS.AG]': Permission denied
ls: cannot access 'foldername/Nocturama (2016) [BluRay] [1080p] [YTS.AM]': Permission denied
total 0
-????????? ? ? ? ?            ? 5EmWdWb_.zip.part
d????????? ? ? ? ?            ? Belen (2025) [1080p] [WEBRip] [5.1] [YTS.MX]
d????????? ? ? ? ?            ? Crimes Of The Future (1970) [1080p] [BluRay] [YTS.MX]
d????????? ? ? ? ?            ? Going In Style (1979) [1080p] [WEBRip] [YTS.MX]
d????????? ? ? ? ?            ? Going In Style (2017) [1080p] [YTS.AG]
d????????? ? ? ? ?            ? Ju-on Black Ghost (2009) [1080p] [BluRay] [YTS.MX]
d????????? ? ? ? ?            ? Nocturama (2016) [BluRay] [1080p] [YTS.AM]
d????????? ? ? ? ?            ? VISTAS
ls: cannot open directory 'foldername/Belen (2025) [1080p] [WEBRip] [5.1] [YTS.MX]': Permission denied
ls: cannot open directory 'foldername/Crimes Of The Future (1970) [1080p] [BluRay] [YTS.MX]': Permission denied
ls: cannot open directory 'foldername/Going In Style (1979) [1080p] [WEBRip] [YTS.MX]': Permission denied
ls: cannot open directory 'foldername/Going In Style (2017) [1080p] [YTS.AG]': Permission denied
ls: cannot open directory 'foldername/Ju-on Black Ghost (2009) [1080p] [BluRay] [YTS.MX]': Permission denied
ls: cannot open directory 'foldername/Nocturama (2016) [BluRay] [1080p] [YTS.AM]': Permission denied
ls: cannot open directory 'foldername/VISTAS': Permission denied

The folder was being used to allocate shared files from qBittorrent.

Sounds plausible. Could the saving of the ZIP file with the folder’s name not modified the folder but the folder’s permissions? :thinking:

EDIT: Indeed.
Looking at folder’s File Properties on PCManFM the Permission to “Access content” was set to “Nobody”. Owner was user. So, just changed it to “Access content: Only owner” and now the folder seems to have gone back to normal.

Execute the command as root user or use sudo…

I can’t tell you how it happened as I don’t exactly what was done and how was it done by saving your zip-folder but something changed the permissions for your folder.

So, is your problem solved with that? Everything that was readable, writable and executable by your user is as it was before?

1 Like

It has part in the name so indicates that the file idownload was incomplete

1 Like

Yes, I just checked and everything seems to be normal again.

The issue is reproducible. I’ve just tested it in a Fedora Workstation box with GNOME and PCManFM with another similar ZIP file: at the moment of saving the file, you name it exactly as some already existent folder (without extension, just name) and then the folder got its “Access content” permission changed to “Nobody” and the ZIP file is saved inside the folder with a .part extension added. Should I report this as a bug somewhere?

Anyway, thanks a lot, everybody. Not only helped me to solve this flawlessly but also in real time. Really awesome. My first experience in openSUSE forum and was a wonderful one. Kind regards!

Good

I am lacking the insight whether this is expected behaviour or a bug. IMHO the reason for that could be the incomplete copy and maybe the permissions for a file just get set after a successful copy process. I tried to trigger the behaviour by generating a .zip-folder, removing permissions and copying it into a folder where a folder with the same name exists. Everything worked normally and the permissions got set to the default.
Did everything from the terminal though.

I just wonder how much PCManFM is still an active project in the GTK-world (as you mentioned using it in Gnome). Since LXDE was merged with razor-qt and moved to LXQt I am not sure it would be worth to report a bug as I don’t know if anyone is still working on the GTK version of PCManFM.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.