Re: problem formating disk with gpart
On 12/1/11 1:48 PM, Robert Huff wrote: > > Damien Fleuriot writes: > >> >> Try this: >> >> gpart delete -i 1 >> >> gpart create -s 78g -i 1 -t freebsd-ufs /dev/ad1 >> > >> > Done >> >> >>> gpart show ad1 >> > => 34 976773101 ad1 GPT (465G) >> > 34 1635778561 freebsd-ufs (78G) >> > 163577890 813195245 - free - (387G) >> > >> >> Then try to newfs -U it. >> > >> > Same error message as above, only with sector # 163577855. >> > >> > >> > For the record: this is being done on: >> > >> > FreeBSD 9.0-BETA1 #0: Tue Aug 23 10:07:23 EDT 2011 amd64 >> > >> >> >> You may want to try on different versions to check if you have >> better results: > > Unfortunately, not an option in my current set-up. > What makes this so puzzling is I have two other GPT disks - > created either with this version or one from mid-April - that got > built with no problems not caused by my own ignorance. > > > Robert Huff > As was pointed out earlier, did you hot-swap the disk, or did you shutdown the system before inserting it ? That might be a lead to follow ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"
Re: problem formating disk with gpart
Damien Fleuriot writes: > >> Try this: > >> gpart delete -i 1 > >> gpart create -s 78g -i 1 -t freebsd-ufs /dev/ad1 > > > >Done > > >>> gpart show ad1 > > => 34 976773101 ad1 GPT (465G) > > 34 1635778561 freebsd-ufs (78G) > > 163577890 813195245 - free - (387G) > > > >> Then try to newfs -U it. > > > >Same error message as above, only with sector # 163577855. > > > > > >For the record: this is being done on: > > > > FreeBSD 9.0-BETA1 #0: Tue Aug 23 10:07:23 EDT 2011 amd64 > > > > > You may want to try on different versions to check if you have > better results: Unfortunately, not an option in my current set-up. What makes this so puzzling is I have two other GPT disks - created either with this version or one from mid-April - that got built with no problems not caused by my own ignorance. Robert Huff ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"
Re: problem formating disk with gpart
On Thu, 01 Dec 2011 02:07:41 -0600, CyberLeo Kitsana wrote: > On 11/30/2011 03:01 PM, Robert Huff wrote: > > > > One of my systems has a hot-swap eSATA device, which reports as > > "ad1". I'm trying to use this to prepare a new disk using gpart and > > something (possibly my understanding) is broken. > > After removing another disk and inserting the new one, I do: > > > >>> gpart show ad1 > > => 34 976773101 ad1 GPT (465G) > > 34 976773101 - free - (465G) > > > > ... which is the value for the disk just removed. > > If I do (to start clean): > > > >>> gpart destroy ad1 > > gpart destroy ad1 > > gpart: Input/output error > > > > Huh? > > If I remember correctly, the old ATA subsystem (ad*) does not support > hotswap notification, so the kernel will not see a device change until > reboot or reinit. You should probably be using AHCI (if the driver > supports your chipset) or very careful use of atacontrol detach, attach, > or reinit. I'm not fully sure if this applies here, but there are the following commands: atacontrol attach channel atacontrol detach channel atacontrol reinit channel atacontrol spindown device [seconds] atacontrol list It seems as they are intended to support "manual hotswapping" to be done with SATA. See "man atacontrol" for details. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"
Re: problem formating disk with gpart
On 11/30/2011 03:01 PM, Robert Huff wrote: > > One of my systems has a hot-swap eSATA device, which reports as > "ad1". I'm trying to use this to prepare a new disk using gpart and > something (possibly my understanding) is broken. > After removing another disk and inserting the new one, I do: > >>> gpart show ad1 > => 34 976773101 ad1 GPT (465G) > 34 976773101 - free - (465G) > > ... which is the value for the disk just removed. > If I do (to start clean): > >>> gpart destroy ad1 > gpart destroy ad1 > gpart: Input/output error > > Huh? If I remember correctly, the old ATA subsystem (ad*) does not support hotswap notification, so the kernel will not see a device change until reboot or reinit. You should probably be using AHCI (if the driver supports your chipset) or very careful use of atacontrol detach, attach, or reinit. -- Fuzzy love, -CyberLeo Technical Administrator CyberLeo.Net Webhosting http://www.CyberLeo.Net Furry Peace! - http://.fur.com/peace/ ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"
Re: problem formating disk with gpart
On 12/1/11 4:51 AM, Robert Huff wrote: > > I'm not sure how, but I have achieved this: > >>> gpart show ad1 > => 34 976773101 ad1 GPT (465G) > 34 9767731011 freebsd-ufs (465G) > > ... which is correct, except for the size. > I have a new problem: > >>> newfs /dev/ad1p1 > newfs: wtfs: 512 bytes at sector 976773100: Input/output error > You're trying to create a 460gb file system on a 80gb drive. When newfs reaches the drive's boundary and attempts to write to the next sector, it tries to divide by 0 and gets slapped back 9000 years in time by Chuck Norris. Try this: gpart delete -i 1 gpart create -s 78g -i 1 -t freebsd-ufs /dev/ad1 Then try to newfs -U it. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"
Re: problem formating disk with gpart
I'm not sure how, but I have achieved this: >> gpart show ad1 => 34 976773101 ad1 GPT (465G) 34 9767731011 freebsd-ufs (465G) ... which is correct, except for the size. I have a new problem: >> newfs /dev/ad1p1 newfs: wtfs: 512 bytes at sector 976773100: Input/output error Robert Huff ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"
Re: problem formating disk with gpart
On 12/1/11 3:14 AM, Robert Huff wrote: > > Warren Block writes: > >> > One of my systems has a hot-swap eSATA device, which reports as >> > "ad1". I'm trying to use this to prepare a new disk using gpart and >> > something (possibly my understanding) is broken. >> > After removing another disk and inserting the new one, I do: >> > >> >>> gpart show ad1 >> > => 34 976773101 ad1 GPT (465G) >> > 34 976773101 - free - (465G) >> > >> > ... which is the value for the disk just removed. >> >> Maybe force geom retasting? >> >> true > /dev/ad1 > > I did this. > Afterwards, "gpart show" continues to report the 456G vaule, > not the 80G I should see. > > > Robert Huff > Any success using bsdlabel on the disk to initialize it, then fdisk to partition it ? Then report the geom show again. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"
Re: problem formating disk with gpart
Warren Block writes: > >One of my systems has a hot-swap eSATA device, which reports as > > "ad1". I'm trying to use this to prepare a new disk using gpart and > > something (possibly my understanding) is broken. > >After removing another disk and inserting the new one, I do: > > > >>> gpart show ad1 > > => 34 976773101 ad1 GPT (465G) > > 34 976773101 - free - (465G) > > > >... which is the value for the disk just removed. > > Maybe force geom retasting? > > true > /dev/ad1 I did this. Afterwards, "gpart show" continues to report the 456G vaule, not the 80G I should see. Robert Huff ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"
Re: problem formating disk with gpart
On Wed, 30 Nov 2011, Robert Huff wrote: One of my systems has a hot-swap eSATA device, which reports as "ad1". I'm trying to use this to prepare a new disk using gpart and something (possibly my understanding) is broken. After removing another disk and inserting the new one, I do: gpart show ad1 => 34 976773101 ad1 GPT (465G) 34 976773101 - free - (465G) ... which is the value for the disk just removed. Maybe force geom retasting? true > /dev/ad1 ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"
Re: problem formating disk with gpart
On 11/30/11 11:28 PM, Robert Huff wrote: > > Damien Fleuriot writes: > >> >>> gpart destroy ad1 >> > gpart destroy ad1 >> > gpart: Input/output error >> > >> > Huh? >> >> Huh indeed. >> >> Please toggle GEOM debug and try again: >> >> sysctl kern.geom.debugflags=17 > > gpart: device not configured > > However: > >>> ls -al /dev/ad1* > crw-r- 1 root operator0, 80 Nov 30 15:39 /dev/ad1 > crw-r- 1 root operator0, 96 Nov 27 17:58 /dev/ad10 > crw-r- 1 root operator0, 102 Nov 27 17:58 /dev/ad10p1 > crw-r- 1 root operator0, 103 Nov 27 12:58 /dev/ad10p2 > I have no trouble setting the sysctl here: mybsd root /usr/src/sbin/sysctl # sysctl kern.geom.debugflags=17 kern.geom.debugflags: 0 -> 17 mybsd root /usr/src/sbin/sysctl # sysctl kern.geom.debugflags=0 kern.geom.debugflags: 17 -> 0 mybsd root /usr/src/sbin/sysctl # kldstat Id Refs AddressSize Name 1 19 0x8010 93db60 kernel 21 0x80a3e000 bcc0 geom_label.ko 31 0x80a4a000 210c8geom_mirror.ko 41 0x80a6c000 f060 aio.ko 51 0x80c12000 132008 zfs.ko 61 0x80d45000 f489 krpc.ko 71 0x80d55000 1ff1 opensolaris.ko 81 0x80d57000 22f1 ums.ko Please post: - kldstat - kldstat -v | grep g_part If appropriate, kldload the geom_label module , just in case, although I don't think this should be related. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"
Re: problem formating disk with gpart
On 11/30/11 10:01 PM, Robert Huff wrote: > > One of my systems has a hot-swap eSATA device, which reports as > "ad1". I'm trying to use this to prepare a new disk using gpart and > something (possibly my understanding) is broken. > After removing another disk and inserting the new one, I do: > >>> gpart show ad1 > => 34 976773101 ad1 GPT (465G) > 34 976773101 - free - (465G) > > ... which is the value for the disk just removed. > If I do (to start clean): > >>> gpart destroy ad1 > gpart destroy ad1 > gpart: Input/output error > > Huh? > Huh indeed. Please toggle GEOM debug and try again: sysctl kern.geom.debugflags=17 ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"