View topic - Cannot mount partition from build file.
Cannot mount partition from build file.
2 posts
• Page 1 of 1
Cannot mount partition from build file.
This is a follow-up from my previous posting regarding the use of mkdir and problems with a read-only operating system.
I have now successfully partitioned a USB stick into two partitions. The first partition contains the QNX image and is 256M in size. I can boot from this USB partition. The second partition fills the remaining space of my 16G USB stick and is formatted as FAT32 with a volume label of "B".
Once booted I can mount the second partition using "mount -v -t dos /dev/hd0t12 /B" and access it from the "/B" directory.
However, I have to manually type in this command every time I boot. I really want to do this automatically from the script in the build file, but if I attempt this it fails every time saying:
mount: Can't mount /B (type dos)
mount: Possible reason: Invalid argument
Here is the end of the script in the build file:
display_msg "Mounting DOS partition..."
mount -v -t dos /dev/hd0t12 /B
# Run the script on the second partition (mounted as /B) which is intended to start whatever
# software is installed.
/B/start
# Then start a Korn shell.
ksh -l
So:
a) Why is it that I cannot mount the partition whilst in the build script, but I can once the Korn shell starts?
b) How can I automatically mount the partition at boot time?
I have now successfully partitioned a USB stick into two partitions. The first partition contains the QNX image and is 256M in size. I can boot from this USB partition. The second partition fills the remaining space of my 16G USB stick and is formatted as FAT32 with a volume label of "B".
Once booted I can mount the second partition using "mount -v -t dos /dev/hd0t12 /B" and access it from the "/B" directory.
However, I have to manually type in this command every time I boot. I really want to do this automatically from the script in the build file, but if I attempt this it fails every time saying:
mount: Can't mount /B (type dos)
mount: Possible reason: Invalid argument
Here is the end of the script in the build file:
display_msg "Mounting DOS partition..."
mount -v -t dos /dev/hd0t12 /B
# Run the script on the second partition (mounted as /B) which is intended to start whatever
# software is installed.
/B/start
# Then start a Korn shell.
ksh -l
So:
a) Why is it that I cannot mount the partition whilst in the build script, but I can once the Korn shell starts?
b) How can I automatically mount the partition at boot time?
- RichardE2
- New Member
- Posts: 4
- Joined: Thu Oct 26, 2017 9:13 am
Re: Cannot mount partition from build file.
Guessing the environment is different once you start the ksh.
But you can run a ksh command from within the build script...
ksh -c "mount -v -t dos /dev/hd0t12 /B"
The ksh will return when mount exits.
But you can run a ksh command from within the build script...
ksh -c "mount -v -t dos /dev/hd0t12 /B"
The ksh will return when mount exits.
- denkelly
- Senior Member
- Posts: 162
- Joined: Sat Aug 02, 2008 3:27 pm
2 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 5 guests