Score:1

Can't mount VHD file in Read-write mode using terminal

tr flag

I have a VHD file which I am using a bash script to mount, I run this in sudo:


#!/bin/bash
cd /home/user/Desktop/VMfiles
echo "make sure to unmount the VHD before starting up the vm, as theres a risk of corruption if the file is mounted in both OSes."
sleep .5
chmod ugo+rwx disk-1.vhd
sleep .5
vhdimount -X allow_root disk-1.vhd /mnt/vhd/
sleep .5
mount -vt ntfs-3g -o ro,noload,offset=32256 /mnt/vhd/vhdi1 /media/user/your/folder

The command can only mount the vhd file in read only mode, and if I attempt to switch this command:


mount -vt ntfs-3g -o ro,noload,offset=32256 /mnt/vhd/vhdi1 /media/user/your/folder

to this,

mount -vt ntfs-3g -o rw,noload,offset=32256 /mnt/vhd/vhdi1 /media/user/your/folder

This error message appears:

ntfs-3g-mount: mount failed: Permission denied
Failed to sync device /dev/loop0: Input/output error
Failed to close volume /dev/loop0: Input/output error


Whats going on here?
How can I enable read-write mode?
OS: Ubuntu 18.04

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.