Priority: P3 — important, not urgent. The hostname is still saved in netOrk; it just never reaches the host.
What happens
Changing a Linux device's hostname on its netOrk detail page saves it, then shows:
Hostname saved, but could not be applied to device: The driver linux does not support set_hostname()
netOrk's POST /devices/{id}/apply-hostname checks implements(driver_cls, "set_hostname") before connecting, and LinuxDriver (pin c00deef, also main) has no such method. OPNsense, Proxmox and OpenWrt implement it.
What it needs
set_hostname(new_hostname) on LinuxDriver, accepting a bare name or an FQDN:
hostnamectl set-hostname <short> where systemd is present, falling back to writing /etc/hostname + hostname <short>.
/etc/hosts: replace the old name on the 127.0.1.1 line (Debian/Ubuntu convention) with <fqdn> <short> or <short>; leave other lines alone.
Validate the name (RFC 1123 labels) before anything is written, since it ends up in a privileged shell.
/etc/mailname and cloud-init's preserve_hostname are worth a look: on a cloud-init host, an unset preserve_hostname reverts the name on the next boot.
napalm-proxmox's set_hostname (system_mixin.py) already does the Debian file edits; the shared part could move to a common place rather than being written twice.
Related netOrk ticket: the UI attempts the apply for drivers that lack the method (filed alongside this one).
Priority: P3 — important, not urgent. The hostname is still saved in netOrk; it just never reaches the host.
## What happens
Changing a Linux device's hostname on its netOrk detail page saves it, then shows:
> Hostname saved, but could not be applied to device: The driver linux does not support set_hostname()
netOrk's `POST /devices/{id}/apply-hostname` checks `implements(driver_cls, "set_hostname")` before connecting, and `LinuxDriver` (pin `c00deef`, also `main`) has no such method. OPNsense, Proxmox and OpenWrt implement it.
## What it needs
`set_hostname(new_hostname)` on `LinuxDriver`, accepting a bare name or an FQDN:
- `hostnamectl set-hostname <short>` where systemd is present, falling back to writing `/etc/hostname` + `hostname <short>`.
- `/etc/hosts`: replace the old name on the `127.0.1.1` line (Debian/Ubuntu convention) with `<fqdn> <short>` or `<short>`; leave other lines alone.
- Validate the name (RFC 1123 labels) before anything is written, since it ends up in a privileged shell.
- `/etc/mailname` and cloud-init's `preserve_hostname` are worth a look: on a cloud-init host, an unset `preserve_hostname` reverts the name on the next boot.
`napalm-proxmox`'s `set_hostname` (`system_mixin.py`) already does the Debian file edits; the shared part could move to a common place rather than being written twice.
Related netOrk ticket: the UI attempts the apply for drivers that lack the method (filed alongside this one).
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Priority: P3 — important, not urgent. The hostname is still saved in netOrk; it just never reaches the host.
What happens
Changing a Linux device's hostname on its netOrk detail page saves it, then shows:
netOrk's
POST /devices/{id}/apply-hostnamechecksimplements(driver_cls, "set_hostname")before connecting, andLinuxDriver(pinc00deef, alsomain) has no such method. OPNsense, Proxmox and OpenWrt implement it.What it needs
set_hostname(new_hostname)onLinuxDriver, accepting a bare name or an FQDN:hostnamectl set-hostname <short>where systemd is present, falling back to writing/etc/hostname+hostname <short>./etc/hosts: replace the old name on the127.0.1.1line (Debian/Ubuntu convention) with<fqdn> <short>or<short>; leave other lines alone./etc/mailnameand cloud-init'spreserve_hostnameare worth a look: on a cloud-init host, an unsetpreserve_hostnamereverts the name on the next boot.napalm-proxmox'sset_hostname(system_mixin.py) already does the Debian file edits; the shared part could move to a common place rather than being written twice.Related netOrk ticket: the UI attempts the apply for drivers that lack the method (filed alongside this one).
netOrk side: NetOrk/netork#1671