0

This question already has an answer here:

OS: 17.10 and Win10.

I am dual-booting Windows and Ubuntu. I can read and execute all files from my Windows partition. I can't delete them from Thunar, though. I ran as sudo and got the same result.

They're both on the same hard drive, but obviously partitioned. Is there any way I can delete Windows files from Ubuntu, or do I have to log into Windows to do that? I don't care about system safety, I'm working on reducing my files so I can eventually just delete the Windows partition completely.

EDIT: Windows is mounted. When I unmount it, I can't read or execute the files, let alone delete them.

EDIT #2: When trying to delete from the command line, I get the following error:

rm: cannot remove 'file.exe': Read-only file system

When running the command mount, I get a lot of output back:

sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=3993752k,nr_inodes=998438,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=804052k,mode=755)
/dev/sda5 on / type ext4 (rw,relatime,errors=remount-ro,data=ordered)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/unified type cgroup2 (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/rdma type cgroup (rw,nosuid,nodev,noexec,relatime,rdma)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=28,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=13322)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
mqueue on /dev/mqueue type mqueue (rw,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
configfs on /sys/kernel/config type configfs (rw,relatime)
/var/lib/snapd/snaps/mailspring_86.snap on /snap/mailspring/86 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/atom_109.snap on /snap/atom/109 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/mailspring_77.snap on /snap/mailspring/77 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/brackets_21.snap on /snap/brackets/21 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/hugo_1012.snap on /snap/hugo/1012 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/core_3604.snap on /snap/core/3604 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/core_3440.snap on /snap/core/3440 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/vscode_21.snap on /snap/vscode/21 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/brackets_46.snap on /snap/brackets/46 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/mailspring_96.snap on /snap/mailspring/96 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/atom_76.snap on /snap/atom/76 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/atom_106.snap on /snap/atom/106 type squashfs (ro,nodev,relatime)
/var/lib/snapd/snaps/vscode_20.snap on /snap/vscode/20 type squashfs (ro,nodev,relatime)
/dev/sda2 on /media/radhika/System type fuseblk (ro,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)
/dev/sda3 on /media/radhika/Windows type fuseblk (ro,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=804048k,mode=700,uid=1000,gid=1000)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
/dev/fuse on /run/user/1000/doc type fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
/var/lib/snapd/snaps/vscode_22.snap on /snap/vscode/22 type squashfs (ro,nodev,relatime)

I tried to get the output of /etc/fstab, the system says that folder does not exist.

marked as duplicate by karel, David Foerster, George Udosen, Eric Carvalho, waltinator Dec 27 '17 at 4:33

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 1
    "I can't delete them from Thunar" – What happens when you try? Any error messages? If so what do they say exactly? You can select, copy and paste most dialogue texts in Ubuntu. – David Foerster Dec 22 '17 at 4:01
  • The option is simply grayed out. Windows is on an NTFS filesystem, if that helps. – Radhika Morabia Dec 22 '17 at 4:19
  • 1
    Try deleting from the console (but be careful); do you get error messages, and which? And what's the output of the command mount? Please add these details to your question. – Murphy Dec 22 '17 at 10:17
  • Can you include the contents of /etc/fstab in your question? – WinEunuuchs2Unix Dec 22 '17 at 12:28
  • Updated to answer all of the above questions. – Radhika Morabia Dec 22 '17 at 19:19
1

Open a terminal Type sudo mount -o remount,rw /disk/location /mount/location

You just unmounted and remounted your disk as R/W so anyone can read - write. Make sure to do sudo umount /disk/location when you are done, because if anyone wants to do harm they can write to the disk now!

Try lsblk for your disk location and when you want to regenerate your fstab, just reboot.

  • Thanks! This worked. In hindsight, I should've realized it was a permission issue. I thought being able to execute would mean I should be able to delete the files. – Radhika Morabia Dec 22 '17 at 19:49
  • rebooting does not regenerate /etc/fstab. Did you mean something else that I am not aware of? – Zanna Dec 22 '17 at 22:11
  • maybe try askubuntu.com/questions/81726/… – Yoran Jansen Dec 23 '17 at 14:47

Not the answer you're looking for? Browse other questions tagged or ask your own question.