-
Notifications
You must be signed in to change notification settings - Fork 374
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ubuntu 18.04 --deprovision causes host name to become localhost #1398
Comments
Deprovision is expected to throw away the hostname; the whole point is that a deprovisioned VM isn't a VM at all, it's an image which is used to provision a new VM with its own identity and hostname. The interesting question is: how were you able to create a new VM from the image without setting the hostname as part of the provisioning process? |
If you are asking about the os.profile computer name its there. |
more findings : seem like when i use the deprovision the ovf-env.xml is not getting created. attaching my boot diagnostics. Welcome to �[1mUbuntu 18.04.1 LTS�[0m! [ 11.602256] systemd[1]: Set hostname to <localhost.localdomain>. [ 22.678931] cloud-init[731]: util.del_file(self.paths.instance_link)
[ 25.047895] [�[0;32m OK �[0m] cloud-init[1137]: ci-info: | Route | Destination | Gateway | Genmask | Interface | Flags |Listening on ACPID Listen Socket. [[ 25.063717] �[0;32m OK �[0mcloud-init[1137]: ] ci-info: +-------+-----------------+----------+-----------------+-----------+-------+Started Daily apt download activities. [ 25.072219] [cloud-init�[0;32m OK �[0m[1137]: ] ci-info: | 0 | 0.0.0.0 | 10.0.1.1 | 0.0.0.0 | eth0 | UG |Started Daily apt upgrade and clean activities. [ 25.087712] cloud-init [1137]: Starting LXD - unix socket.ci-info: | 1 | 10.0.1.0 | 0.0.0.0 | 255.255.255.0 | eth0 | U | [[ 25.108807] �[0;32m OK �[0mcloud-init] [1137]: Listening on D-Bus System Message Bus Socket.ci-info: | 2 | 168.63.129.16 | 10.0.1.1 | 255.255.255.255 | eth0 | UGH | [[ 25.125102] �[0;32m OK �[0mcloud-init] [1137]: Started Daily Cleanup of Temporary Directories.ci-info: | 3 | 169.254.169.254 | 10.0.1.1 | 255.255.255.255 | eth0 | UGH | [[ 25.139648] �[0;32m OK �[0m] cloud-initReached target Timers.[1137]: [ 25.170214] [cloud-init�[0;32m OK �[0m[1137]: ] ci-info: +-------+-------------+---------+-----------+-------+Listening on UUID daemon activation socket. [ 25.183385] [cloud-init�[0;32m OK �[0m[1137]: ] ci-info: | Route | Destination | Gateway | Interface | Flags |Reached target Cloud-config availability. [ 25.196824] [cloud-init�[0;32m OK �[0m[1137]: ] ci-info: +-------+-------------+---------+-----------+-------+Listening on Socket activation for snappy daemon. [ 25.209478] cloud-init[1137]: ci-info: | 0 | fe80::/64 | :: | eth0 | U | [�[0;32m OK �[0m] Reached target Basic System. [ 25.276816] Starting LXD - container startup/shutdown... [ 25.298594] [�[0;32m OK �[0m] Started Hyper-V File Copy Protocol Daemon. [ 25.377317] cloud-init[1137]: [ return self._get_data_source(existing=existing)�[0;32m OK �[0m] [�[0;32m OK �[0m] Started D-Bus System Message Bus. [ 53.934686] cloud-init[1679]: 2018/11/17 16:28:12.462879 INFO Clean protocol 2018/11/17 16:28:12.501945 INFO WireServer endpoint is not found. Rerun dhcp handler See 'systemctl status cloud-config.service' for details.[ 54.027815] 2018/11/17 16:28:12.554495 INFO Fabric preferred wire protocol version:2015-04-05 cloud-init[1679]: util.del_file(self.paths.instance_link) [ 54.123575] cloud-init[1679]: ------------------------------------------------------------ U2018/11/17 16:28:14.441672 INFO Installed Agent WALinuxAgent-2.2.20 is the most current agent localhost login: 2018/11/17 16:28:14.718557 INFO Agent WALinuxAgent-2.2.20 is running as the goal state agent Chain FORWARD (policy ACCEPT 0 packets, 0 bytes) Chain OUTPUT (policy ACCEPT 0 packets, 0 bytes) 2018/11/17 16:28:16.536103 INFO ExtHandler Set block dev timeout: sdb with timeout: 300 |
after a lot of trying and testing i found the issue but dont know the rca for this:
am still puzzeled as for why ovf-env.xml is not pushed. |
I am also seeing this. I only started seeing this after upgrading from WALinuxAgent-2.2.33 -> WALinuxAgent-2.2.34 to solve another issue I was seeing (#1394). |
Closing this item since both @digeler and @1008covingtonlane have found a workaround. |
Hi, I am seeing this bug again in waagent version 2.3.1.1, and Ubuntu 18.04, platform image. |
@anamariaduta can you describe the exact steps you took so that we can try to reproduce this issue? Ubuntu 18.04 marketplace images in Azure should be using cloud-init to provision and waagent will yield provisioning to cloud-init. Hostname is set by cloud-init and not waagent. |
Operating System: Ubuntu 18.04.1 LTS
Kernel: Linux 4.15.0-1021-azure
Architecture: x86-64
root@localhost:/# hostnamectl
Static hostname: localhost.localdomain
Icon name: computer-vm
Chassis: vm
Machine ID: c6ab5a0378da4d5e8cf2a4becdb7ed0e
Boot ID: 65906c36c38b4f17a2060e455c1e2060
Virtualization: microsoft
Operating System: Ubuntu 18.04.1 LTS
Kernel: Linux 4.15.0-1021-azure
Architecture: x86-64
market place image .
here is what I did :
download 18.04 from market place
installed software
waagent --deprovision
generalised
created a vm from the image then host name is: localhost.localdomain
expected behaviour should keep the hostname.
to change the hostname I followed this : https://linuxize.com/post/how-to-change-hostname-on-ubuntu-18-04/
I couldn't reproduce it anymore With new image.
please tell me what can be the reason for this behaviour
The text was updated successfully, but these errors were encountered: