Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #179381 > unrolled thread
| Started by | kAt <giathnygeia@openmailbox.org> |
|---|---|
| First post | 2017-03-26 19:40 +0200 |
| Last post | 2017-03-27 19:40 +0200 |
| Articles | 20 on this page of 76 — 21 participants |
Back to article view | Back to linux.debian.user
DD bs=4M option on USB mem-stick creates false format kAt <giathnygeia@openmailbox.org> - 2017-03-26 19:40 +0200
Re: DD bs=4M option on USB mem-stick creates false format Darac Marjal <mailinglist@darac.org.uk> - 2017-03-26 19:50 +0200
Re: DD bs=4M option on USB mem-stick creates false format Richard Owlett <rowlett@cloud85.net> - 2017-03-26 20:00 +0200
Re: DD bs=4M option on USB mem-stick creates false format kAt <giathnygeia@openmailbox.org> - 2017-03-26 20:10 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-26 20:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format kAt <giathnygeia@openmailbox.org> - 2017-03-27 12:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-27 14:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-27 14:40 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-28 12:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format Richard Owlett <rowlett@cloud85.net> - 2017-03-28 14:00 +0200
Re: DD bs=4M option on USB mem-stick creates false format <tomas@tuxteam.de> - 2017-03-28 14:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format Richard Owlett <rowlett@cloud85.net> - 2017-03-28 15:50 +0200
Re: DD bs=4M option on USB mem-stick creates false format <tomas@tuxteam.de> - 2017-03-28 15:50 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-28 16:30 +0200
Re: DD bs=4M option on USB mem-stick creates false format Richard Owlett <rowlett@cloud85.net> - 2017-03-28 17:40 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-28 19:10 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-28 14:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format <tomas@tuxteam.de> - 2017-03-28 14:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format Richard Owlett <rowlett@cloud85.net> - 2017-03-28 14:40 +0200
Re: DD bs=4M option on USB mem-stick creates false format Richard Owlett <rowlett@cloud85.net> - 2017-03-28 15:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format songbird <songbird@anthive.com> - 2017-03-28 19:30 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-28 20:40 +0200
Re: DD bs=4M option on USB mem-stick creates false format songbird <songbird@anthive.com> - 2017-03-29 07:50 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-29 10:30 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-29 12:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-29 12:40 +0200
Re: DD bs=4M option on USB mem-stick creates false format kAt <giathnygeia@openmailbox.org> - 2017-03-29 00:50 +0200
Re: DD bs=4M option on USB mem-stick creates false format songbird <songbird@anthive.com> - 2017-03-29 07:50 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-29 10:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format kAt <giathnygeia@openmailbox.org> - 2017-03-29 22:30 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-30 00:00 +0200
Re: DD bs=4M option on USB mem-stick creates false format Curt <curty@free.fr> - 2017-03-29 16:40 +0200
Re:Movie 'n Book recommendations by Curt kAt <giathnygeia@openmailbox.org> - 2017-03-29 22:10 +0200
Re: Movie 'n Book recommendations by Curt Lisi Reisz <lisi.reisz@gmail.com> - 2017-03-29 23:40 +0200
Re: Movie 'n Book recommendations by Curt kAt <giathnygeia@openmailbox.org> - 2017-03-30 20:10 +0200
Re: Movie 'n Book recommendations by Curt Lisi Reisz <lisi.reisz@gmail.com> - 2017-03-30 20:20 +0200
Re: Movie 'n Book recommendations by Curt Richard Owlett <rowlett@cloud85.net> - 2017-03-30 20:50 +0200
Re: Movie 'n Book recommendations by Curt Catherine Gramze <rhiamom@mac.com> - 2017-03-30 20:30 +0200
Re: Movie 'n Book recommendations by Curt Eike Lantzsch <zp6cge@gmx.net> - 2017-03-30 20:40 +0200
Re: Movie 'n Book recommendations by Curt John Hasler <jhasler@newsguy.com> - 2017-03-30 21:30 +0200
Re: Movie 'n Book recommendations by Curt Terence <terence.john@gmail.com> - 2017-03-30 22:00 +0200
Re: Movie 'n Book recommendations by Curt Catherine Gramze <rhiamom@mac.com> - 2017-03-30 22:40 +0200
Re: Movie 'n Book recommendations by Curt Lisi Reisz <lisi.reisz@gmail.com> - 2017-03-31 00:20 +0200
Re: Movie 'n Book recommendations by Curt Catherine Gramze <rhiamom@mac.com> - 2017-03-31 01:30 +0200
Re: Movie 'n Book recommendations by Curt Jonathan Dowland <jmtd@debian.org> - 2017-03-31 09:50 +0200
Re: Movie 'n Book recommendations by Curt Terence <terence.john@gmail.com> - 2017-03-31 12:40 +0200
OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) rhkramer@gmail.com - 2017-03-31 15:10 +0200
Re: OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) Lisi Reisz <lisi.reisz@gmail.com> - 2017-03-31 15:40 +0200
Re: OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) Greg Wooledge <wooledg@eeg.ccf.org> - 2017-03-31 15:50 +0200
Re: OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) rhkramer@gmail.com - 2017-03-31 16:20 +0200
Re: OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) Eike Lantzsch <zp6cge@gmx.net> - 2017-03-31 16:30 +0200
Re: OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) Curt <curty@free.fr> - 2017-03-31 18:00 +0200
Re: OT: speaking of days (weeks, months, years, etc.) kAt <giathnygeia@openmailbox.org> - 2017-04-01 00:20 +0200
Re: OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) rhkramer@gmail.com - 2017-03-31 16:20 +0200
Re: OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) Lisi Reisz <lisi.reisz@gmail.com> - 2017-03-31 17:00 +0200
Re: OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) Liam O'Toole <liam.p.otoole@gmail.com> - 2017-04-01 19:20 +0200
Re: OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) Lisi Reisz <lisi.reisz@gmail.com> - 2017-04-01 20:10 +0200
Re: OT: speaking of days (weeks, months, years, etc.) (was: Re: Movie 'n Book recommendations by Curt) Liam O'Toole <liam.p.otoole@gmail.com> - 2017-04-01 21:30 +0200
Re: OT: speaking of days (weeks, months, years, etc.) Peter Hillier-Brook <phb@hbsys.plus.com> - 2017-03-31 17:20 +0200
Re: OT: speaking of days (weeks, months, years, etc.) kAt <giathnygeia@openmailbox.org> - 2017-04-01 00:20 +0200
Re: OT: speaking of days (weeks, months, years, etc.) Lisi Reisz <lisi.reisz@gmail.com> - 2017-04-01 00:50 +0200
Re: OT: speaking of days (weeks, months, years, etc.) GiaThnYgeia <GiaThnYgeia@openmailbox.org> - 2017-04-01 18:10 +0200
Re: OT: speaking of days (weeks, months, years, etc.) Stefan Monnier <monnier@iro.umontreal.ca> - 2017-03-31 16:50 +0200
Re: OT: speaking of days (weeks, months, years, etc.) Lisi Reisz <lisi.reisz@gmail.com> - 2017-03-31 17:00 +0200
Re: OT: speaking of days (weeks, months, years, etc.) Eike Lantzsch <zp6cge@gmx.net> - 2017-03-31 17:10 +0200
Re: OT: speaking of days (weeks, months, years, etc.) kAt <giathnygeia@openmailbox.org> - 2017-04-01 00:40 +0200
Re: DD bs=4M option on USB mem-stick creates false format Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-03-27 21:00 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-27 21:50 +0200
Re: DD bs=4M option on USB mem-stick creates false format David Christensen <dpchrist@holgerdanske.com> - 2017-03-27 06:10 +0200
Re: DD bs=4M option on USB mem-stick creates false format kAt <giathnygeia@openmailbox.org> - 2017-03-27 14:10 +0200
Re: DD bs=4M option on USB mem-stick creates false format rhkramer@gmail.com - 2017-03-27 14:30 +0200
Re: DD bs=4M option on USB mem-stick creates false format Greg Wooledge <wooledg@eeg.ccf.org> - 2017-03-27 14:40 +0200
Re: DD bs=4M option on USB mem-stick creates false format "Thomas Schmitt" <scdbackup@gmx.net> - 2017-03-27 15:10 +0200
Re: DD bs=4M option on USB mem-stick creates false format David Christensen <dpchrist@holgerdanske.com> - 2017-03-27 20:20 +0200
Re: DD bs=4M option on USB mem-stick creates false format Pascal Hambourg <pascal@plouf.fr.eu.org> - 2017-03-28 00:00 +0200
Re: DD bs=4M option on USB mem-stick creates false format David Christensen <dpchrist@holgerdanske.com> - 2017-03-27 19:40 +0200
Page 1 of 4 [1] 2 3 4 Next page →
| From | kAt <giathnygeia@openmailbox.org> |
|---|---|
| Date | 2017-03-26 19:40 +0200 |
| Subject | DD bs=4M option on USB mem-stick creates false format |
| Message-ID | <tpkiZ-3bf-3@gated-at.bofh.it> |
dd if=/media/------/image.iso of=/dev/sdb bs=4M; sync the image works but the format of the drive seems false gparted when starting says that linux thinks it is a 256k block and not the 4m it indicates. It shows on an 8G drive an empty space of 28G Is it the option of bs=4M that creates this problem. The free space can not be formatted and partitioned. As Gparted tried to claim and format this space as a 6.7G which seemed right it crashed. Any advise would greatly be appreciated kAt-rin
[toc] | [next] | [standalone]
| From | Darac Marjal <mailinglist@darac.org.uk> |
|---|---|
| Date | 2017-03-26 19:50 +0200 |
| Message-ID | <tpksF-3f3-5@gated-at.bofh.it> |
| In reply to | #179381 |
"dd ... bs=4M" doesn't change the block size of the underlying device. All it does is say that dd should copy in chunks of 4Mb. If the buffer size is bigger, then dd spends more time copying and less time telling the kernel to copy. On 26/03/17 18:18, kAt wrote: > dd if=/media/------/image.iso of=/dev/sdb bs=4M; sync > > the image works but the format of the drive seems false > gparted when starting says that linux thinks it is a 256k block and not > the 4m it indicates. It shows on an 8G drive an empty space of 28G > > Is it the option of bs=4M that creates this problem. The free space can > not be formatted and partitioned. As Gparted tried to claim and format > this space as a 6.7G which seemed right it crashed. > > Any advise would greatly be appreciated > kAt-rin >
[toc] | [prev] | [next] | [standalone]
| From | Richard Owlett <rowlett@cloud85.net> |
|---|---|
| Date | 2017-03-26 20:00 +0200 |
| Message-ID | <tpkCl-3iY-11@gated-at.bofh.it> |
| In reply to | #179381 |
On 03/26/2017 12:18 PM, kAt wrote:
> dd if=/media/------/image.iso of=/dev/sdb bs=4M; sync
>
> the image works but the format of the drive seems false
> gparted when starting says that linux thinks it is a 256k block and not
> the 4m it indicates. It shows on an 8G drive an empty space of 28G
>
> Is it the option of bs=4M that creates this problem. The free space can
> not be formatted and partitioned. As Gparted tried to claim and format
> this space as a 6.7G which seemed right it crashed.
>
> Any advise would greatly be appreciated
> kAt-rin
I don't know anything about "why", but I regularly see it with Jessie.
Can't recall if it was present with Squeeze {I skipped Wheezy for OT
reasons}.
[toc] | [prev] | [next] | [standalone]
| From | kAt <giathnygeia@openmailbox.org> |
|---|---|
| Date | 2017-03-26 20:10 +0200 |
| Message-ID | <tpkM2-3F0-13@gated-at.bofh.it> |
| In reply to | #179381 |
kAt: > dd if=/media/------/image.iso of=/dev/sdb bs=4M; sync > > the image works but the format of the drive seems false > gparted when starting says that linux thinks it is a 256k block and not > the 4m it indicates. It shows on an 8G drive an empty space of 28G > > Is it the option of bs=4M that creates this problem. The free space can > not be formatted and partitioned. As Gparted tried to claim and format > this space as a 6.7G which seemed right it crashed. > > Any advise would greatly be appreciated > kAt-rin Correction to the error message, it is this: The driver descriptor says the physical block size is 2048 bytes, but Linux says it is 512 bytes. or at least that is what I get without using the bs=4M option I am wondering whether it is a fault of the iso image (recent download of the Rescatux 4.0beta) which I am trying to use without luck on an old 32bit Celeron?? .. with Win XP to repair its admin pass and booting which seems to take for ever. I am trying to use the empty part of the stick to copy and store temporatily some important files before I mess with it or install debian kAt
[toc] | [prev] | [next] | [standalone]
| From | "Thomas Schmitt" <scdbackup@gmx.net> |
|---|---|
| Date | 2017-03-26 20:20 +0200 |
| Message-ID | <tpkVI-3IL-1@gated-at.bofh.it> |
| In reply to | #179381 |
Hi, kAt wrote: > dd if=/media/------/image.iso of=/dev/sdb bs=4M; sync > the image works but the format of the drive seems false The dd option "bs=" has no influence on the block size or other drive properties as perceived by a partition editor. > gparted when starting says that linux thinks it is a 256k block and not > the 4m it indicates. Normally a USB stick has a block size of 512 bytes. Are you sure you use the term "block" in the appropriate way ? > It shows on an 8G drive an empty space of 28G Very syspicious. Which Debian ISO exactly do you use ? What exactly does it report ? What do these two commands report: /sbin/fdisk -l /dev/sdb echo 2 | /sbin/gdisk -l /dev/sdb > As Gparted tried to claim and format > this space as a 6.7G which seemed right it crashed. Even more suspicious. > Any advise would greatly be appreciated The GPT in Debian ISOs is of few use. I would erase its header block by: dd if=/dev/zero bs=512 seek=1 count=1 of=/dev/sdb and then try again with a partition editor. Have a nice day :) Thomas
[toc] | [prev] | [next] | [standalone]
| From | kAt <giathnygeia@openmailbox.org> |
|---|---|
| Date | 2017-03-27 12:20 +0200 |
| Message-ID | <tpzUJ-6u4-17@gated-at.bofh.it> |
| In reply to | #179390 |
Thomas Schmitt: > Hi, > > kAt wrote: >>> /sbin/fdisk -l /dev/sdb >> Disk /dev/sdb: 7.2 GiB, 7751073792 bytes, 15138816 sectors > > Is this about the correct size of the stick ? I suppose this is normal for an 8Gb usb stick. 249Mb go to firmware that operates the stick???? I wouldn't know. >> Units: sectors of 1 * 512 = 512 bytes >> Sector size (logical/physical): 512 bytes / 512 bytes >> I/O size (minimum/optimal): 512 bytes / 512 bytes > > Looks like a normal block size for USB sticks and conventional disks. So where does the false alert come from on Gparted about the 2048b? Is it a problem with the way I restore the iso, a problem with the iso that Rescatux forces (I wouldn't think so) or a problem with the stick itself? >> Device Boot Start End Sectors Size Id Type >> /dev/sdb1 * 64 1374207 1374144 671M 0 Empty >> /dev/sdb2 1297212 1298619 1408 704K ef EFI (FAT-12/16/32) > > This is the MBR partition table. You may use fdisk to add a partition. > (Let's hope it will not hate that sdb2 is located inside sdb1.) why does this happen? Again this is not an iso I created but downloaded from Rescatux >> echo 2 | sudo /sbin/gdisk -l /dev/sdb >> Warning! Main partition table overlaps the first partition by 64 blocks! >> You will need to delete this partition or resize it in another utility. > > gdisk definitively hates the start of the outer partition. > But starting at block 64 would mean that it would not be mountable. So fdisk uses things differently than gdisk, or is the one using the other? >> Number Start (sector) End (sector) Size Code Name >> 2 1297212 1298619 704.0 KiB 0700 ISOHybrid1 > > The EFI partition is more to its taste. The EFI part is sdb2, right? Which resides inside sdb1? > As said, the GPT of an ISO with "mjg" layout is quite useless > and i'd zeroize its header block at block address 1. So it is normal that if you write such an iso in a 64Gb stick 63Gb remain useless as long as this system is on it? Strange but still clueless of what all this means ... > Have a nice day :) You too > Thomas I am very far from undersdanding this but it is interesting to keep at it? kAt
[toc] | [prev] | [next] | [standalone]
| From | "Thomas Schmitt" <scdbackup@gmx.net> |
|---|---|
| Date | 2017-03-27 14:20 +0200 |
| Message-ID | <tpBMR-7V7-3@gated-at.bofh.it> |
| In reply to | #179430 |
Hi, kAt wrote: > >> Disk /dev/sdb: 7.2 GiB, 7751073792 bytes, 15138816 sectors > [...] > I suppose this is normal for an 8Gb usb stick. 249Mb go to firmware that > operates the stick???? Hardly. Unless it is an operating-system-on-a-stick. The habit on the storage sector is to count by SI compliant mega and giga. I.e. millions and billions. 7.77511 billion is not 8 giga. (Well, you can be lucky if it is not a fake stick which maps more than one logical block address onto the same physical block. Or one that pretends to be a USB keyboard and begins to reprogram your computer.) > So where does the false alert come from on Gparted about the 2048b? Please show the gparted messages which worry you. > [from other mail:] Rescatux 4.0beta > > Is it a problem with the way I restore the iso, a problem with the iso > that Rescatux forces (I wouldn't think so) or a problem with the stick > itself? It is most probably a problem with the partition tables in the ISO. wget 'https://downloads.sourceforge.net/project/rescatux/rescatux_0_40_b11/rescatux-0.40b11.iso' xorriso -indev rescatux-0.40b11.iso -report_system_area plain shows the same "mjg" layout as Debian installation ISOs: - MBR partition table with nested partitions (some partition editors hate this). - GPT partition table not properly announced by "Protective MBR" and with nested partitions (doubly hated). - APM partition table with block size 2048 (look here for a suspect !) This collection of little sins and contradictions is enough reason for any partition editor to bail out. We should reduce the list to the MBR nested partition sin. > I am trying to use the empty part of the stick to copy and store > temporatily some important files Well understood. You should clean out the surplus partition table headers iso=/dev/sdb # Remove GPT header block. # I add option conv=notrunc for the case this is done with a image file # rather than a device file. It prevents truncation of the file. dd if=/dev/zero conv=notrunc bs=512 seek=1 count=1 of="$iso" # Overwrite APM Block0 signature by unchanged isohybrid MBR start # provided by Debian package "isolinux" since oldstable Debian. # # We want these bytes, and isohdpfx.bin is their cheapest source: # 33 ed 90 90 90 90 90 90 90 90 90 90 90 90 90 90 # 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 dd if=/usr/lib/ISOLINUX/isohdpfx.bin conv=notrunc bs=1 count=32 of="$iso" Then try to find a partition editor which tolerates the nested MBR partitions. Last resort: If no partition editor is willing to work, we could patch some numbers into MBR partition slot 3 to make us a partition by hand. These bytes: 00 ff ff ff 83 ff ff ff bc d0 13 00 44 2f d3 00 at byte position 478 would do this trick: Device Boot Start End Sectors Size Id Type test.iso1 * 64 1374207 1374144 671M 0 Empty test.iso2 1297212 1298619 1408 704K ef EFI (FAT-12/16/32) test.iso3 1298620 15138815 13840196 6.6G 83 Linux i wrote: > > You may use fdisk to add a partition. > > (Let's hope it will not hate that sdb2 is located inside sdb1.) > why does this happen? Because xorriso built it according to the BIOS+EFI isohybrid layout as developed by Matthew Garrett (mjg) in 2010. Rescatux people used something named LIVE-BUILD 5.0_A11-1; HTTP://LIVE-SYSTEMS.ORG/DEVEL/LIVE-BUILD which obviously ran xorriso. This layout with several partition tables shall boot on as many BIOSes and EFIs as possible. Usefulness for partition editors is only a secondary consideration. > So fdisk uses things differently than gdisk, or is the one using the other? Yes. They are different programs. fdisk is mainly for MBR partition tables, gdisk is mainly for GPT. Since i propose to remove the not-so-good GPT and APM, fdisk should be your first try afterwards. > The EFI part is sdb2, right? Which resides inside sdb1? sdb1 makes the whole ISO filesystem mountable. It has partition type 0x00 (= "Empty") because else EFI would refuse to accept the partition of type 0xef (= "EFI") which sits inside sdb1. > So it is normal that if you write such an iso in a 64Gb stick 63Gb > remain useless as long as this system is on it? Good question. Hardly any partition editor really helps to clean up the mess. So, yes, it is quite normal that adding a partition to mjg's partition table equipment is cumbersome. I made some effort in the recent years to enable a less tangled layout based solely on MBR partitions, with the EFI boot image outside the ISO so that there emerge no nested partitions. grub-mkrescue on the other hand offers a partition-editor-friendly layout based entirely on GPT (if no appleisms are configured to go into the ISO). The ISO itself is not mountable by a partition then. But understandably, the distros are not very eager to make experiments with their ISOs, which on the first hand shall boot and not be nice to partition editors. > I am very far from undersdanding this but it is interesting to keep at it? Sure. Maybe we even develop a program to de-mjg-ize an installed ISO for systems which do not need GPT or APM, and to then claim the remaining space as MBR partition 3. Have a nice day :) Thomas
[toc] | [prev] | [next] | [standalone]
| From | "Thomas Schmitt" <scdbackup@gmx.net> |
|---|---|
| Date | 2017-03-27 14:40 +0200 |
| Message-ID | <tpC6e-83W-11@gated-at.bofh.it> |
| In reply to | #179441 |
Hi, my hand made partition 3 fell victim to the deceptions of nested partitions. It starts inside the ISO after the end of partition 2. It should of course start after the end of partition 1. So this is not the right start of partition 3: > Device Boot Start End Sectors Size Id Type > test.iso1 * 64 1374207 1374144 671M 0 Empty > test.iso2 1297212 1298619 1408 704K ef EFI (FAT-12/16/32) > test.iso3 1298620 15138815 13840196 6.6G 83 Linux By bytes 00 ff ff ff 83 ff ff ff 00 f8 14 00 00 08 d2 00 i get a more desirable result: Device Boot Start End Sectors Size Id Type test.iso1 * 64 1374207 1374144 671M 0 Empty test.iso2 1297212 1298619 1408 704K ef EFI (FAT-12/16/32) test.iso3 1374208 15138815 13764608 6.6G 83 Linux Have a nice day :) Thomas
[toc] | [prev] | [next] | [standalone]
| From | "Thomas Schmitt" <scdbackup@gmx.net> |
|---|---|
| Date | 2017-03-28 12:20 +0200 |
| Message-ID | <tpWoi-65Z-17@gated-at.bofh.it> |
| In reply to | #179446 |
Hi,
i wrote a small program which shall make a USB stick with isohybrid ISO
more digestible for partition editors by removing all partition tables
except MBR partitions.
It then creates a new partition in the first MBR partition slot which
is found with block count 0.
usage: ./make_isombr_part file_path partition_end partition_type
Creates a partition in a free slot of an isohybrid MBR in an ISO.
Removes GPT and APM signatures if present.
file_path must lead to a file or device with isohybrid ISO.
partition_end tells the number of 512-byte blocks of device.
partiton_end value "auto" means full number of device blocks.
partition_type is a hex number in the range of 00 to ff.
Type examples: 83 = Linux , 0c = FAT32 , 17 = Hidden NTFS
Binary compiled on Debian 8 (you may need to give it x-permission after
download):
http://scdbackup.webframe.org/make_isombr_part
MD5: 4856af2c1b50a775325a3e6c09d7d9bc
Source code:
http://scdbackup.webframe.org/make_isombr_part.c
The argument "auto" currently works only on Linux kernels.
On other systems one has to give the block number explicitely.
------------------------------------------------------------------------
See a test run with rescatux ISO on /dev/sdc (any current Debian i386
or amd64 ISO would be suitable, too).
Still less dangerous than manipulating /dev files as superuser is
to give the world temporary permission to the one stick in question:
$ sudo chmod o+rw /dev/sdc
(The program is supposed to refuse if it does not find an isohybrid ISO.
But better do not bet on those safety measures.)
Let the program remove APM and GPT and add a MBR partition:
$ chmod u+x ./make_isombr_part
$ ./make_isombr_part /dev/sdc auto 83
Note: Storage capacity of '/dev/sdc' : 3915776 blocks
Note: Wrote MBR partition slot 3, type 0x83, start 1374208, blocks 2541568
Note: Removed APM signature
Note: Removed GPT signature at block 1
Note: Removed GPT signature at block 1374207
Afterwards, fdisk reports the new partiton table:
$ /sbin/fdisk -l /dev/sdc
Disk /dev/sdc: 1.9 GiB, 2004877312 bytes, 3915776 sectors
...
Device Boot Start End Sectors Size Id Type
/dev/sdc1 * 64 1374207 1374144 671M 0 Empty
/dev/sdc2 1297212 1298619 1408 704K ef EFI (FAT-12/16/32)
/dev/sdc3 1374208 3915775 2541568 1.2G 83 Linux
When done, exclude the world from directly reading and altering the stick
content:
$ sudo chmod o-rw /dev/sdc
Best unplug the stick and put it in again, so that the operating system
takes notice of the new partition table situation.
------------------------------------------------------------------------
It would be interesting to see how various partition editors react on
this state of the USB stick. Can they reduce the size of partition 3 ?
Can they remove partition 3 and add on new one ?
------------------------------------------------------------------------
Have a nice day :)
Thomas
[toc] | [prev] | [next] | [standalone]
| From | Richard Owlett <rowlett@cloud85.net> |
|---|---|
| Date | 2017-03-28 14:00 +0200 |
| Message-ID | <tpXX4-72Y-11@gated-at.bofh.it> |
| In reply to | #179517 |
On 03/28/2017 05:10 AM, Thomas Schmitt wrote:
>[snip]
>
> It would be interesting to see how various partition editors react on
> this state of the USB stick. Can they reduce the size of partition 3 ?
> Can they remove partition 3 and add on new one ?
>
That looked interesting. As I had a flash drive with Jessie's netinst on
it, I did a test run. It was not successful. The md5 of the code was
correct.
I am running Debian 8.6.0 with MATE desktop.
Clicking on the drive's icon and selecting properties reports:
Name: Debian 8.7.1 M-A 1
Type: folder (inode/directory)
Contents: 2,613 items, totalling 614.6 MB
Location: on the desktop
Volume: Debian 8.7.1 M-A 1
Filesystem type: isofs
A copy-n-paste from my terminal is:
richard@march-9-Jessie:~$ su
Password:
root@march-9-Jessie:/home/richard# /sbin/fdisk -l /dev/sdb
Disk /dev/sdb: 7.2 GiB, 7746879488 bytes, 15130624 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x0400c414
Device Boot Start End Sectors Size Id Type
/dev/sdb1 * 0 1140735 1140736 557M 0 Empty
/dev/sdb2 4156 5531 1376 688K ef EFI (FAT-12/16/32)
root@march-9-Jessie:/home/richard# chmod o+rw /dev/sdb
root@march-9-Jessie:/home/richard# exit
richard@march-9-Jessie:~$ chmod u+x /home/richard/Downloads/make_isombr_part
richard@march-9-Jessie:~$ /home/richard/Downloads/make_isombr_part
/dev/sdb auto 83
bash: /home/richard/Downloads/make_isombr_part: cannot execute binary
file: Exec format error
richard@march-9-Jessie:~$
Operator error or other?
HTH
[toc] | [prev] | [next] | [standalone]
| From | <tomas@tuxteam.de> |
|---|---|
| Date | 2017-03-28 14:20 +0200 |
| Message-ID | <tpYgq-7p2-13@gated-at.bofh.it> |
| In reply to | #179520 |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Tue, Mar 28, 2017 at 06:53:08AM -0500, Richard Owlett wrote: > On 03/28/2017 05:10 AM, Thomas Schmitt wrote: > >[snip] > > > >It would be interesting to see how various partition editors react on > >this state of the USB stick. Can they reduce the size of partition 3 ? > >Can they remove partition 3 and add on new one ? > > > > That looked interesting. As I had a flash drive with Jessie's > netinst on it, I did a test run. It was not successful. The md5 of > the code was correct. > > I am running Debian 8.6.0 with MATE desktop. > Clicking on the drive's icon and selecting properties reports: > Name: Debian 8.7.1 M-A 1 > Type: folder (inode/directory) > Contents: 2,613 items, totalling 614.6 MB > Location: on the desktop > Volume: Debian 8.7.1 M-A 1 > Filesystem type: isofs > > A copy-n-paste from my terminal is: > richard@march-9-Jessie:~$ su > Password: > root@march-9-Jessie:/home/richard# /sbin/fdisk -l /dev/sdb > > Disk /dev/sdb: 7.2 GiB, 7746879488 bytes, 15130624 sectors > Units: sectors of 1 * 512 = 512 bytes > Sector size (logical/physical): 512 bytes / 512 bytes > I/O size (minimum/optimal): 512 bytes / 512 bytes > Disklabel type: dos > Disk identifier: 0x0400c414 > > Device Boot Start End Sectors Size Id Type > /dev/sdb1 * 0 1140735 1140736 557M 0 Empty > /dev/sdb2 4156 5531 1376 688K ef EFI (FAT-12/16/32) > > root@march-9-Jessie:/home/richard# chmod o+rw /dev/sdb > root@march-9-Jessie:/home/richard# exit > richard@march-9-Jessie:~$ chmod u+x /home/richard/Downloads/make_isombr_part > richard@march-9-Jessie:~$ /home/richard/Downloads/make_isombr_part > /dev/sdb auto 83 > bash: /home/richard/Downloads/make_isombr_part: cannot execute > binary file: Exec format error > richard@march-9-Jessie:~$ I'd guess there's a difference between Thomas's processor architecture and yours. For a first stab, try those: file /home/richard/Downloads/make_isombr_part file /bin/ls (Yes, I know Richard's box can be multiarch, but that'd be the next stab :) > Operator error or other? It's always the operator ;-) ;-) Regards - -- tomás -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iEYEARECAAYFAljaVF0ACgkQBcgs9XrR2kb4WQCdFgfGvGg5Fiza1YkFxT46dBwU 08EAnAzpRviC4dxHv8W5xbXs/swzH1Qt =GCoF -----END PGP SIGNATURE-----
[toc] | [prev] | [next] | [standalone]
| From | Richard Owlett <rowlett@cloud85.net> |
|---|---|
| Date | 2017-03-28 15:50 +0200 |
| Message-ID | <tpZFy-8kZ-77@gated-at.bofh.it> |
| In reply to | #179521 |
On 03/28/2017 07:17 AM, tomas@tuxteam.de wrote: > [snip] > > I'd guess there's a difference between Thomas's processor architecture > and yours. [snip] Recompiled for my architecture successfully. Did a successful minimal install from my modified flash drive. > >> Operator error or other? > > It's always the operator ;-) ;-) Me? Paranoid? No the world's against me ;! Now if days were only 48 hours long.
[toc] | [prev] | [next] | [standalone]
| From | <tomas@tuxteam.de> |
|---|---|
| Date | 2017-03-28 15:50 +0200 |
| Message-ID | <tpZFy-8kZ-75@gated-at.bofh.it> |
| In reply to | #179528 |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Tue, Mar 28, 2017 at 08:41:52AM -0500, Richard Owlett wrote: > On 03/28/2017 07:17 AM, tomas@tuxteam.de wrote: > >[snip] > > > >I'd guess there's a difference between Thomas's processor architecture > >and yours. [snip] > > Recompiled for my architecture successfully. > Did a successful minimal install from my modified flash drive. Yes, saw that passing by. > >>Operator error or other? > > > >It's always the operator ;-) ;-) > > Me? Paranoid? No the world's against me ;! The fact that you're paranoid doesn't mean that they aren't after you. > Now if days were only 48 hours long. I'd be interested in that too. regards - -- t -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iEYEARECAAYFAljaaVEACgkQBcgs9XrR2kZx2wCfWEQ8yFuUwPTu9Dmg1NuEtfby Xi4AnjalGOCepsn0jGqqRv01AcXueVhN =i2Gp -----END PGP SIGNATURE-----
[toc] | [prev] | [next] | [standalone]
| From | "Thomas Schmitt" <scdbackup@gmx.net> |
|---|---|
| Date | 2017-03-28 16:30 +0200 |
| Message-ID | <tq0id-ss-11@gated-at.bofh.it> |
| In reply to | #179528 |
Hi, Richard Owlett wrote: > /dev/sdb3 1140736 15130623 13989888 6.7G 83 Linux For the records (as Richard obviously knew it already): After the run of make_isombr_part, the new partition has no filesystem. The commands mkfs or mkdosfs would be the next step, or some GUI tool for managing disk partitions. The purpose of make_isombr_part is two-fold: - Make the partitioning as normal as possible by removing APM and GPT. This shall keep the usual partition editors from hating the stick. - Compensate for the remaining flaw of partition 2 sitting inside partition 1 by adding a preliminary MBR partition up to the given block address or up to the device end. One may well try to manage the stick by a partition editor. But if everything else fails, this partition is better than nothing. > Disk /dev/sdb: 7.2 GiB, 7746879488 bytes, 15130624 sectors And what did the merchants write in their advertising ? 8 GB ? Have a nice day :) Thomas
[toc] | [prev] | [next] | [standalone]
| From | Richard Owlett <rowlett@cloud85.net> |
|---|---|
| Date | 2017-03-28 17:40 +0200 |
| Message-ID | <tq1nY-1do-17@gated-at.bofh.it> |
| In reply to | #179532 |
On 03/28/2017 09:20 AM, Thomas Schmitt wrote: > Hi, > > Richard Owlett wrote: >> /dev/sdb3 1140736 15130623 13989888 6.7G 83 Linux > > For the records (as Richard obviously knew it already): If you believe that line, would you like to by a Brooklyn Bridge? It was legitimately for sale in late 1960's (located in Tompkins County not NY,NY ;) > > After the run of make_isombr_part, the new partition has no > filesystem. > The commands mkfs or mkdosfs would be the next step, or some GUI tool > for managing disk partitions. > > > The purpose of make_isombr_part is two-fold: > > - Make the partitioning as normal as possible by removing APM and GPT. > This shall keep the usual partition editors from hating the stick. > > - Compensate for the remaining flaw of partition 2 sitting inside > partition 1 by adding a preliminary MBR partition up to the given > block address or up to the device end. > One may well try to manage the stick by a partition editor. > But if everything else fails, this partition is better than nothing. Appropriate search terms that would lead to learning "howto"? > > >> Disk /dev/sdb: 7.2 GiB, 7746879488 bytes, 15130624 sectors > > And what did the merchants write in their advertising ? 8 GB ? That's what the bubble pack said. > > > Have a nice day :) > > Thomas > >
[toc] | [prev] | [next] | [standalone]
| From | "Thomas Schmitt" <scdbackup@gmx.net> |
|---|---|
| Date | 2017-03-28 19:10 +0200 |
| Message-ID | <tq2N4-2mE-7@gated-at.bofh.it> |
| In reply to | #179533 |
Hi,
i wrote:
> > One may well try to manage the stick by a partition editor.
Richard Owlett wrote:
> Appropriate search terms that would lead to learning "howto"?
"linux"-or-"yourdesktop" together with "partition editor".
The reason to start this thread was about "gparted". We saw output of
"fdisk" and "gdisk". All three are for command line and/or text dialog.
The desktops will surely have their own graphical tools.
I expect that they handle partitioning and also file system creation.
My own approach with creating a filesystem would be "man mkfs"
"This mkfs frontend is deprecated in favour of filesystem specific
mkfs.<type> utils.
[...]
SEE ALSO
fs(5), badblocks(8), fsck(8), mkdosfs(8), mke2fs(8), mkfs.bfs(8),
mkfs.ext2(8), mkfs.ext3(8), mkfs.ext4(8), mkfs.minix(8), mkfs.msdos(8),
mkfs.vfat(8), mkfs.xfs(8)"
Well, i'd need to decide for a filesystem type anyways.
If it's for exchange of files with MS-Windows or Mac, then mkfs.msdos
or mkfs.vfat.
If it's for Linux only with need for linux-ly filenames and file
properties, then rather mkfs.ext2, 3, or 4.
The words "mkfs.msdos", "mkfs.vfat", "mkfs.ext2", "mkfs.ext3", "mkfs.ext4"
in Google yield interesting info.
Have a nice day :)
Thomas
[toc] | [prev] | [next] | [standalone]
| From | "Thomas Schmitt" <scdbackup@gmx.net> |
|---|---|
| Date | 2017-03-28 14:20 +0200 |
| Message-ID | <tpYgq-7p2-21@gated-at.bofh.it> |
| In reply to | #179520 |
Hi, Richard Owlett wrote: > I am running Debian 8.6.0 with MATE desktop. > ... > bash: /home/richard/Downloads/make_isombr_part: cannot execute binary file: > Exec format error Can it be your system is equipped with Debian for architecture i386 ? I forgot to mention that my system is amd64. > Operator error or other? Probably my error. I forgot the many architectures supported by Debian. I should have advertised building from source. So please download: http://scdbackup.webframe.org/make_isombr_part.c MD5: 85e89cec6173e889693e8466d7cad763 If you do not have program /usr/bin/cc yet, then install package "build-essential", which provides the equipment for the C language. To build your own binary, do in the directory where you have the file make_isombr_part.c : cc -g -Wall -o make_isombr_part make_isombr_part.c This command should end quickly without any messages. If messages appear, then please show them. If all is well, a new file make_isombr_part is supposed to have emerged and to have rx-permissions at least for its owner. That's your executable binary. Sorry for the inconvenience. Have a nice day :) Thomas
[toc] | [prev] | [next] | [standalone]
| From | <tomas@tuxteam.de> |
|---|---|
| Date | 2017-03-28 14:20 +0200 |
| Message-ID | <tpYgr-7p2-63@gated-at.bofh.it> |
| In reply to | #179522 |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Tue, Mar 28, 2017 at 02:16:24PM +0200, Thomas Schmitt wrote: [...] > http://scdbackup.webframe.org/make_isombr_part.c Yummy source. Now we're talking :-) (trapped at work ATM. But I'll sure look into that) regards - -- t -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iEYEARECAAYFAljaVLsACgkQBcgs9XrR2kZpVwCdHqHTuL6384KDLQ9L4aZWWl1Z yXYAnRqVhvtt3Kfqtnnsr2M/NxkiHqG5 =gwns -----END PGP SIGNATURE-----
[toc] | [prev] | [next] | [standalone]
| From | Richard Owlett <rowlett@cloud85.net> |
|---|---|
| Date | 2017-03-28 14:40 +0200 |
| Message-ID | <tpYzP-7we-105@gated-at.bofh.it> |
| In reply to | #179522 |
On 03/28/2017 07:16 AM, Thomas Schmitt wrote: > Hi, > > Richard Owlett wrote: >> I am running Debian 8.6.0 with MATE desktop. >> ... >> bash: /home/richard/Downloads/make_isombr_part: cannot execute binary file: >> Exec format error > > Can it be your system is equipped with Debian for architecture i386 ? Yepp ;/ When I started experimenting with Linux I had a mixture of 32 and 64 bit machines so since Jessie I've been using DVDs labeled as i386. My primary machine is a Lenovo T510. An old www.cnet.com review says it has a Intel Core i7 620M / 2.66 GHz. > I forgot to mention that my system is amd64. > > >> Operator error or other? > > Probably my error. I forgot the many architectures supported by Debian. > I should have advertised building from source. > > So please download: > > http://scdbackup.webframe.org/make_isombr_part.c > > MD5: 85e89cec6173e889693e8466d7cad763 > > If you do not have program /usr/bin/cc yet, then install package > "build-essential", which provides the equipment for the C language. > > To build your own binary, do in the directory where you have the > file make_isombr_part.c : > > cc -g -Wall -o make_isombr_part make_isombr_part.c > > This command should end quickly without any messages. > If messages appear, then please show them. > If all is well, a new file > make_isombr_part > is supposed to have emerged and to have rx-permissions at least > for its owner. That's your executable binary. > > Sorry for the inconvenience. There you go trying to educate me in spite of my myself ;/ Last time I compiled anything 8" floppies and 8085's were state of the art. My employer used Intel development systems with PLM. > > > Have a nice day :) > > Thomas > >
[toc] | [prev] | [next] | [standalone]
| From | Richard Owlett <rowlett@cloud85.net> |
|---|---|
| Date | 2017-03-28 15:20 +0200 |
| Message-ID | <tpZcu-88d-37@gated-at.bofh.it> |
| In reply to | #179522 |
On 03/28/2017 07:16 AM, Thomas Schmitt wrote: > [snip] > > To build your own binary, do in the directory where you have the > file make_isombr_part.c : > > cc -g -Wall -o make_isombr_part make_isombr_part.c > > This command should end quickly without any messages. > If messages appear, then please show them. > If all is well, a new file > make_isombr_part > is supposed to have emerged and to have rx-permissions at least > for its owner. That's your executable binary. Looks successful. fdisk now reports Disk /dev/sdb: 7.2 GiB, 7746879488 bytes, 15130624 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disklabel type: dos Disk identifier: 0x0400c414 Device Boot Start End Sectors Size Id Type /dev/sdb1 * 0 1140735 1140736 557M 0 Empty /dev/sdb2 4156 5531 1376 688K ef EFI (FAT-12/16/32) /dev/sdb3 1140736 15130623 13989888 6.7G 83 Linux Now I'm going have to search my links for information about adding preseed.cfg and other useful files to a flash drive with an ISO image on it.
[toc] | [prev] | [next] | [standalone]
Page 1 of 4 [1] 2 3 4 Next page →
Back to top | Article view | linux.debian.user
csiph-web