[Yahoo-eng-team] [Bug 1851438] Re: cloud-init disk_setup fails to partition disk for Ubuntu18

2023-02-22 Thread Alberto Contreras
This bug is believed to be fixed in cloud-init in version 23.1. If this
is still a problem for you, please make a comment and set the state back
to New

Thank you.

** Changed in: cloud-init
   Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to cloud-init.
https://bugs.launchpad.net/bugs/1851438

Title:
  cloud-init disk_setup fails to partition disk for Ubuntu18

Status in cloud-init:
  Fix Released
Status in util-linux package in Ubuntu:
  New
Status in util-linux source package in Xenial:
  New
Status in util-linux source package in Bionic:
  New
Status in util-linux source package in Eoan:
  New
Status in util-linux source package in Focal:
  New

Bug description:
  Pasting disk_setup for cloud-config:

  disk_setup:
/dev/xvde:
   layout: True
   overwrite: False
   type: mbr
  fs_setup:
-device: /dev/xvde
 filesystem: ext4
 label: data
 overwrite: false
 partition: auto

  I want to attach and mount a /data disk on the VM using cloud-init so
  I just want to single partition 100% of the disk.

  Error while running the sfdisk command for partitioning the disk (please see 
attached file).
  OS: Ubuntu18

  How I repro-ed it outside cloud-init environment:
  1. Open XenCenter, add a new disk, say /dev/xvdc
  2. Run `/sbin/sfdisk --Linux --unit=S --force /dev/xvdc` and specify start 
sector as 0. Because from the cloud-init logs and source code, I figured that 
it was picking start sector as 0. Save it and see the error.

To manage notifications about this bug go to:
https://bugs.launchpad.net/cloud-init/+bug/1851438/+subscriptions


-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1851438] Re: cloud-init disk_setup fails to partition disk for Ubuntu18

2019-11-05 Thread Ryan Harper
On trusty; this complains but works.

ubuntu@ubuntu:~$ dpkg --list | grep util-linux
ii  util-linux  2.20.1-5.1ubuntu20.9
   amd64Miscellaneous system utilities
ubuntu@ubuntu:~$ cat /proc/partitions 
major minor  #blocks  name

 2530   10485760 vda
 2531   10484736 vda1
 253   16   10485760 vdb
 253   32366 vdc
  1101048575 sr0
ubuntu@ubuntu:~$ sudo bash
sudo: unable to resolve host ubuntu
root@ubuntu:~# echo "0," | sfdisk --Linux --unit=S --force /dev/vdb 
Checking that no-one is using this disk right now ...
OK

Disk /dev/vdb: 20805 cylinders, 16 heads, 63 sectors/track

sfdisk: ERROR: sector 0 does not have an msdos signature
 /dev/vdb: unrecognized partition table type
Old situation:
No partitions found
Warning: bad partition start (earliest 1)
New situation:
Units = sectors of 512 bytes, counting from 0

   Device BootStart   End   #sectors  Id  System
/dev/vdb1 1  20971519   20971519  83  Linux
/dev/vdb2 0 -  0   0  Empty
/dev/vdb3 0 -  0   0  Empty
/dev/vdb4 0 -  0   0  Empty
Warning: no primary partition is marked bootable (active)
This does not matter for LILO, but the DOS MBR will not boot this disk.
Successfully wrote the new partition table

Re-reading the partition table ...

If you created or changed a DOS partition, /dev/foo7, say, then use dd(1)
to zero the first 512 bytes:  dd if=/dev/zero of=/dev/foo7 bs=512 count=1
(See fdisk(8).)
root@ubuntu:~# cat /proc/partitions 
major minor  #blocks  name

 2530   10485760 vda
 2531   10484736 vda1
 253   16   10485760 vdb
 253   17   10485759 vdb1
 253   32366 vdc
  1101048575 sr0


** Also affects: util-linux (Ubuntu)
   Importance: Undecided
   Status: New

** Also affects: util-linux (Ubuntu Eoan)
   Importance: Undecided
   Status: New

** Also affects: util-linux (Ubuntu Xenial)
   Importance: Undecided
   Status: New

** Also affects: util-linux (Ubuntu Focal)
   Importance: Undecided
   Status: New

** Also affects: util-linux (Ubuntu Bionic)
   Importance: Undecided
   Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to cloud-init.
https://bugs.launchpad.net/bugs/1851438

Title:
  cloud-init disk_setup fails to partition disk for Ubuntu18

Status in cloud-init:
  Triaged
Status in util-linux package in Ubuntu:
  New
Status in util-linux source package in Xenial:
  New
Status in util-linux source package in Bionic:
  New
Status in util-linux source package in Eoan:
  New
Status in util-linux source package in Focal:
  New

Bug description:
  Pasting disk_setup for cloud-config:

  disk_setup:
/dev/xvde:
   layout: True
   overwrite: False
   type: mbr
  fs_setup:
-device: /dev/xvde
 filesystem: ext4
 label: data
 overwrite: false
 partition: auto

  I want to attach and mount a /data disk on the VM using cloud-init so
  I just want to single partition 100% of the disk.

  Error while running the sfdisk command for partitioning the disk (please see 
attached file).
  OS: Ubuntu18

  How I repro-ed it outside cloud-init environment:
  1. Open XenCenter, add a new disk, say /dev/xvdc
  2. Run `/sbin/sfdisk --Linux --unit=S --force /dev/xvdc` and specify start 
sector as 0. Because from the cloud-init logs and source code, I figured that 
it was picking start sector as 0. Save it and see the error.

To manage notifications about this bug go to:
https://bugs.launchpad.net/cloud-init/+bug/1851438/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp