Skip navigation.
Home
The QNX Community Portal

View topic - formatting partition

formatting partition

General Help about QNX

formatting partition

Postby Sgtarky » Wed Feb 06, 2013 1:37 pm

ok, I have a mygig harddrive. I run this command dinit -h /dev/umass0t80 i get this error dinit - block 0: invalid argument
Sgtarky
Active Member
 
Posts: 10
Joined: Thu Jun 09, 2011 7:52 pm

Re: formatting partition

Postby Tim » Wed Feb 06, 2013 5:51 pm

Maybe try the dinit command without the -h since you are attempting to format a USB drive which isn't what -h is for (Compact Flash/HD).

Tim
Tim
Senior Member
 
Posts: 1388
Joined: Wed Mar 10, 2004 12:28 am

Re: formatting partition

Postby denkelly » Wed Feb 06, 2013 6:28 pm

Can you use' fdisk /dev/umass0' successfully?

BTW "80" is not a QNX partition type - though it is not relevant to the failure.
denkelly
Senior Member
 
Posts: 160
Joined: Sat Aug 02, 2008 3:27 pm

Re: formatting partition

Postby Sgtarky » Wed Feb 06, 2013 7:26 pm

thanks for your replies I will try with out the -h. yes I can fdisk umass0, but I have do -z. I know 80 is not qnx but that is what all the howto's tell me to do, however in linux fdisk list the partation as 50. and the howto's said to do dinit -h
Sgtarky
Active Member
 
Posts: 10
Joined: Thu Jun 09, 2011 7:52 pm

Re: formatting partition

Postby maschoen » Wed Feb 06, 2013 7:44 pm

I'd suggest two tests.

Your comment that you need to use -z suggests a problem.
Do you need -z each time you run dinit?
You should only need to use it once, that is if it worked the first time.

To do more evaluation, I suggest the following:

1) Run check on the drive, see if dcheck can read the sectors.

2) Run spatch on the disk. Edit and save data on the first sector and quit.
Then run spatch again to see if the data was saved.

While most USB drives work fine with QNX 6.5, there are some that cause problems.
If this drive is not working, I suggest trying another.
maschoen
QNX Master
 
Posts: 2640
Joined: Wed Jun 25, 2003 5:18 pm

Re: formatting partition

Postby Sgtarky » Wed Feb 06, 2013 7:50 pm

ok, I will try these test this evening. I have to use -z option with fdisk or it doesn't work. It is a good possibility both drives I am trying this on are bad.
Sgtarky
Active Member
 
Posts: 10
Joined: Thu Jun 09, 2011 7:52 pm

Re: formatting partition

Postby denkelly » Wed Feb 06, 2013 8:28 pm

You have to use -z because the partition table signature is likely bad. However, you are clearly not able to write to the disk to correct it. Can you write to the disk from Linux or Windows? Maybe the hardware is bad?

>>>in linux fdisk list the partation as 50
50h is 80 decimal.
denkelly
Senior Member
 
Posts: 160
Joined: Sat Aug 02, 2008 3:27 pm

Re: formatting partition

Postby Sgtarky » Thu Feb 07, 2013 2:15 am

ok, i ran some of those commands and it seems to be fine, no errors....now I can do fdisk /dev/umass0 without the -z. however the dinit -h gave me the same error, Yes I read the options -h is to initialize a hard drive, it is a harddrive hooked to usb. I am downloading a drive tester i suspect either the harddrive has some bad sectors of the usb controller is crapped out. i had used this drive for bootcamp(Mac0s) of windows 8.
Sgtarky
Active Member
 
Posts: 10
Joined: Thu Jun 09, 2011 7:52 pm

Re: formatting partition

Postby Sgtarky » Thu Feb 07, 2013 3:05 am

western digitial diag finds no faults on the quick test
Sgtarky
Active Member
 
Posts: 10
Joined: Thu Jun 09, 2011 7:52 pm

Re: formatting partition

Postby denkelly » Thu Feb 07, 2013 12:12 pm

Maybe the drive has 4K sectors? If so, you need to put it in 512-byte sector emulation mode.
denkelly
Senior Member
 
Posts: 160
Joined: Sat Aug 02, 2008 3:27 pm

Re: formatting partition

Postby Sgtarky » Thu Feb 07, 2013 2:21 pm

i have to figure out how to tell if it is 4k sectors. the only reason I am doing this is because the orginal harddrive's 4th partition contains mp3s, for some reason they quit displaying on the headunit and I cannot add new files, the other partitions contain mapdata which still works. when i plug that drive into qnx the 4th partition does not show up. I used clonezilla and copied it to the new harddrive. Sometimes when I boot qnx with the drive attached all 4 parts show up as /fs/hd010-qnx4-1 thru 4 so i drill down thru the 4th part and lo and behold there are my mp3's from orginal drive. but once i mess around in it the part disappears and each other part disappears as i access them. I then disconnect and reconnect the usb drive, now they become /dev/umass0t77 thru 80
Sgtarky
Active Member
 
Posts: 10
Joined: Thu Jun 09, 2011 7:52 pm

Re: formatting partition

Postby Sgtarky » Mon Feb 11, 2013 12:58 pm

no help?

i tried mount -t80 /dev/hd1t80 -t50 /disk
mount: can't mount / (type nonqnx)
mount: possible reason : can't access shared library
Sgtarky
Active Member
 
Posts: 10
Joined: Thu Jun 09, 2011 7:52 pm

Re: formatting partition

Postby denkelly » Mon Feb 11, 2013 7:22 pm

>>>i tried mount -t80 /dev/hd1t80 -t50 /disk

mount -tqnx4 /dev/hd1t80 /disk

The -t option to mount must resolve to the name of a dll as in "fs-qnx4.so".
denkelly
Senior Member
 
Posts: 160
Joined: Sat Aug 02, 2008 3:27 pm

Re: formatting partition

Postby Sgtarky » Tue Feb 12, 2013 1:14 pm

so...the fix?
Sgtarky
Active Member
 
Posts: 10
Joined: Thu Jun 09, 2011 7:52 pm

Re: formatting partition

Postby maschoen » Tue Feb 12, 2013 6:56 pm

One solution would be to number the partition 77, 78 or 79.
maschoen
QNX Master
 
Posts: 2640
Joined: Wed Jun 25, 2003 5:18 pm

Next

Return to Help

Who is online

Users browsing this forum: No registered users and 3 guests