1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Error pve-cluster[main] crit: Unable to get local IP address

Discussion in 'Proxmox VE: Installation and configuration' started by hostingroup, Jul 17, 2012.

  1. hostingroup

    hostingroup New Member

    Joined:
    Feb 7, 2012
    Messages:
    4
    Likes Received:
    0
    Hi I have a Debian Squeeze 64 bits, I'm installing Proxmox, and I get an error:

    root@fast:~# aptitude install proxmox-ve-2.6.32
    Code:
    The following partially installed packages will be configured:
      clvm fence-agents-pve libpve-access-control libpve-storage-perl proxmox-ve-2.6.32 pve-cluster pve-manager qemu-server
      redhat-cluster-pve resource-agents-pve vzctl
    No packages will be installed, upgraded, or removed.
    0 packages upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
    Need to get 0 B of archives. After unpacking 0 B will be used.
    Setting up pve-cluster (1.0-26) ...
    Starting pve cluster filesystem : pve-cluster[main] crit: Unable to get local IP address
     (warning).
    invoke-rc.d: initscript pve-cluster, action "start" failed.
    dpkg: error processing pve-cluster (--configure):
     subprocess installed post-installation script returned error exit status 255
    configured to not write apport reports
                                          dpkg: dependency problems prevent configuration of redhat-cluster-pve:
     redhat-cluster-pve depends on pve-cluster; however:
      Package pve-cluster is not configured yet.
    dpkg: error processing redhat-cluster-pve (--configure):
     dependency problems - leaving unconfigured
    configured to not write apport reports
                                          dpkg: dependency problems prevent configuration of fence-agents-pve:
     fence-agents-pve depends on redhat-cluster-pve; however:
      Package redhat-cluster-pve is not configured yet.
    dpkg: error processing fence-agents-pve (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of libpve-access-control:
     libpve-access-control depends on pve-cluster; however:
      Package pve-cluster is not configured yet.
    configured to not write apport reports
                                          configured to not write apport reports
                                                                                dpkg: error processing libpve-access-control (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of clvm:
     clvm depends on redhat-cluster-pve; however:
      Package redhat-cluster-pve is not configured yet.
    dpkg: error processing clvm (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of libpve-storage-perl:
     libpve-storage-perl depends on clvm; however:
      Package clvm is not configured yet.
    dpkg: error processing libpve-storage-perl (--configure):
     dependency problems - leaving unconfigured
    configured to not write apport reports
                                          configured to not write apport reports
                                                                                dpkg: dependency problems prevent configuration of qemu-server:
     qemu-server depends on libpve-storage-perl; however:
      Package libpve-storage-perl is not configured yet.
     qemu-server depends on pve-cluster; however:
      Package pve-cluster is not configured yet.
     qemu-server depends on redhat-cluster-pve; however:
      Package redhat-cluster-pve is not configured yet.
    dpkg: error processing qemu-server (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of resource-agents-pve:
     resource-agents-pve depends on redhat-cluster-pve; however:
      Package redhat-cluster-pve is not configured yet.
    dpkg: error processing resource-agents-pve (--configure):
     dependency problems - leaving unconfigured
    configured to not write apport reports
                                          configured to not write apport reports
                                                                                dpkg: dependency problems prevent configuration of pve-manager:
     pve-manager depends on qemu-server (>= 1.1-1); however:
      Package qemu-server is not configured yet.
     pve-manager depends on pve-cluster; however:
      Package pve-cluster is not configured yet.
     pve-manager depends on libpve-storage-perl; however:
      Package libpve-storage-perl is not configured yet.
     pve-manager depends on libpve-access-control; however:
      Package libpve-access-control is not configured yet.
     pve-manager depends on redhat-cluster-pve; however:
      Package redhat-cluster-pve is not configured yet.
     pve-manager depends on resource-agents-pve; however:
      Package resource-agents-pve is not configured yet.
     pve-manager depends on fence-agents-pve; however:
      Package fence-agents-pve is not configured yet.
    dpkg: error processing pve-manager (--configure):
     dependency problems - leaving unconfigured
    configured to not write apport reports
                                          dpkg: dependency problems prevent configuration of vzctl:
     vzctl depends on pve-cluster; however:
      Package pve-cluster is not configured yet.
     vzctl depends on libpve-storage-perl; however:
      Package libpve-storage-perl is not configured yet.
    dpkg: error processing vzctl (--configure):
     dependency problems - leaving unconfigured
    configured to not write apport reports
                                          dpkg: dependency problems prevent configuration of proxmox-ve-2.6.32:
     proxmox-ve-2.6.32 depends on pve-manager; however:
      Package pve-manager is not configured yet.
     proxmox-ve-2.6.32 depends on qemu-server; however:
      Package qemu-server is not configured yet.
     proxmox-ve-2.6.32 depends on vzctl (>= 3.0.29); however:
      Package vzctl is not configured yet.
    dpkg: error processing proxmox-ve-2.6.32 (--configure):
     dependency problems - leaving unconfigured
    configured to not write apport reports
                                          Errors were encountered while processing:
     pve-cluster
     redhat-cluster-pve
     fence-agents-pve
     libpve-access-control
     clvm
     libpve-storage-perl
     qemu-server
     resource-agents-pve
     pve-manager
     vzctl
     proxmox-ve-2.6.32
    E: Sub-process /usr/bin/dpkg returned an error code (1)
    A package failed to install.  Trying to recover:
    Setting up pve-cluster (1.0-26) ...
    Starting pve cluster filesystem : pve-cluster[main] crit: Unable to get local IP address
     (warning).
    invoke-rc.d: initscript pve-cluster, action "start" failed.
    dpkg: error processing pve-cluster (--configure):
     subprocess installed post-installation script returned error exit status 255
    dpkg: dependency problems prevent configuration of pve-manager:
     pve-manager depends on pve-cluster; however:
      Package pve-cluster is not configured yet.
    dpkg: error processing pve-manager (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of proxmox-ve-2.6.32:
     proxmox-ve-2.6.32 depends on pve-manager; however:
      Package pve-manager is not configured yet.
    dpkg: error processing proxmox-ve-2.6.32 (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of libpve-access-control:
     libpve-access-control depends on pve-cluster; however:
      Package pve-cluster is not configured yet.
    dpkg: error processing libpve-access-control (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of qemu-server:
     qemu-server depends on pve-cluster; however:
      Package pve-cluster is not configured yet.
    dpkg: error processing qemu-server (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of redhat-cluster-pve:
     redhat-cluster-pve depends on pve-cluster; however:
      Package pve-cluster is not configured yet.
    dpkg: error processing redhat-cluster-pve (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of vzctl:
     vzctl depends on pve-cluster; however:
      Package pve-cluster is not configured yet.
    dpkg: error processing vzctl (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of resource-agents-pve:
     resource-agents-pve depends on redhat-cluster-pve; however:
      Package redhat-cluster-pve is not configured yet.
    dpkg: error processing resource-agents-pve (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of fence-agents-pve:
     fence-agents-pve depends on redhat-cluster-pve; however:
      Package redhat-cluster-pve is not configured yet.
    dpkg: error processing fence-agents-pve (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of clvm:
     clvm depends on redhat-cluster-pve; however:
      Package redhat-cluster-pve is not configured yet.
    dpkg: error processing clvm (--configure):
     dependency problems - leaving unconfigured
    dpkg: dependency problems prevent configuration of libpve-storage-perl:
     libpve-storage-perl depends on clvm; however:
      Package clvm is not configured yet.
    dpkg: error processing libpve-storage-perl (--configure):
     dependency problems - leaving unconfigured
    Errors were encountered while processing:
     pve-cluster
     pve-manager
     proxmox-ve-2.6.32
     libpve-access-control
     qemu-server
     redhat-cluster-pve
     vzctl
     resource-agents-pve
     fence-agents-pve
     clvm
     libpve-storage-perl
    
    root@fast:~# cat /etc/hosts
    Code:
    127.0.0.1       localhost
    127.0.0.1       908C3.securedservers.com        908C3
    #127.0.0.1       fast.hostingroup.com   fast
    174.138.160.98  908C3.securedservers.com        908C3
    
    
    # The following lines are desirable for IPv6 capable hosts
    ::1     ip6-localhost ip6-loopback
    fe00::0 ip6-localnet
    ff00::0 ip6-mcastprefix
    ff02::1 ip6-allnodes
    ff02::2 ip6-allrouters
    
    Help please
     
  2. tom

    tom Proxmox Staff Member
    Staff Member

    Joined:
    Aug 29, 2006
    Messages:
    12,035
    Likes Received:
    205
    why do you have this line? remove it.

    Code:
    127.0.0.1       908C3.securedservers.com        908C3
     
  3. tincboy

    tincboy Member

    Joined:
    Apr 13, 2010
    Messages:
    414
    Likes Received:
    0
    I had the same issue just because there was a record for IPv6 of my hostname
    I've comment it out and it got fixed.
     
  4. socke

    socke New Member

    Joined:
    Dec 19, 2012
    Messages:
    1
    Likes Received:
    0
    Same here, thx :)
     
  5. t0mmy

    t0mmy New Member

    Joined:
    Feb 7, 2013
    Messages:
    1
    Likes Received:
    0
    I can confirm that. Had the same problem some time ago.
     
  6. nfdesign

    nfdesign New Member

    Joined:
    Feb 24, 2013
    Messages:
    1
    Likes Received:
    0
    I experienced this problem after installing and configuring shorewall on my proxmox host.
    Instead of commenting out the IPv6 record I have put the record above the IPv4 one, which solved the problem for me.
    Seems pve-cluster just uses the last line it gets from grepping /etc/hosts for the current hostname.
     
  7. tmikaeld

    tmikaeld Member

    Joined:
    Jan 21, 2013
    Messages:
    65
    Likes Received:
    0
    I tried moving the whole IPv6 section above IPv4, still the same error: Unable to get local IP address

    Uncommenting seem to be the only thing that works.

    Will this be fixed in the next version?
     
  8. Flashtek

    Flashtek New Member

    Joined:
    Apr 21, 2013
    Messages:
    2
    Likes Received:
    0
    Personally I feel this should be fixed as a bug fix. I found this 'fix' by google, the people that were awake in #Proxmox were unable to give a defined answer about how to fix it.

    Perhaps a .1 version bump is in order ?
     
  9. tom

    tom Proxmox Staff Member
    Staff Member

    Joined:
    Aug 29, 2006
    Messages:
    12,035
    Likes Received:
    205
    as long as your /etc/hosts is setup in the right way I do not see the problem. here is a correct /etc/hosts from an ISO install.

    Code:
    root@proxmox-6-175:~# cat /etc/hostname
    proxmox-6-175
    
    root@proxmox-6-175:~# cat /etc/hosts
    
    127.0.0.1 localhost.localdomain localhost
    192.168.6.175 proxmox-6-175.proxmox.com proxmox-6-175 pvelocalhost
    
    # The following lines are desirable for IPv6 capable hosts
    
    ::1     ip6-localhost ip6-loopback
    fe00::0 ip6-localnet
    ff00::0 ip6-mcastprefix
    ff02::1 ip6-allnodes
    ff02::2 ip6-allrouters
    ff02::3 ip6-allhosts
    
    root@proxmox-6-175:~#
     
    Landver likes this.
  10. Flashtek

    Flashtek New Member

    Joined:
    Apr 21, 2013
    Messages:
    2
    Likes Received:
    0

    Sure, but if, like me, you have a server hosted elsewhere that doesn't install from the Debian ISO but is rolled out from a template that auto populates the hosts file with both IPv4 AND IPv6 you may find yourself mighty confused.

    I am sure it's not a major undertaking to make this modification...
     
  11. DragonZX

    DragonZX New Member

    Joined:
    Jun 11, 2013
    Messages:
    5
    Likes Received:
    0
    The same error, this solution didn't help
    Original hosts file
    Code:
    # nameserver config
    # IPv4
    127.0.0.1 localhost
    5.9.115.247  mydomain.ru
    #
    # IPv6
    ::1 ip6-localhost ip6-loopback
    fe00::0 ip6-localnet
    ff00::0 ip6-mcastprefix
    ff02::1 ip6-allnodes
    ff02::2 ip6-allrouters
    ff02::3 ip6-allhosts
    
    The empty hosts file also made this error.
    What can I do?
     
  12. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    15,404
    Likes Received:
    178
    Your hosts file does not contain an entry for hostname (only one with the FQDN), so try to add an alias for that like:

    5.9.115.247 mydomain.ru mydomain
     
  13. Ilya Evseev

    Ilya Evseev New Member

    Joined:
    Jun 30, 2012
    Messages:
    6
    Likes Received:
    0
    The same issue and the same workaround.

    Debian 7.5 in Hetzner DC, generated by their InstallImage tool.
     
  14. pas9x

    pas9x New Member

    Joined:
    Oct 23, 2016
    Messages:
    2
    Likes Received:
    1
    Hi dudes. It is because pmxcfs cannot resolve ip-address of your host.
    Go to https://github.com/proxmox/pve-cluster/blob/master/data/src/pmxcfs.c and you can see it on line 803.
    Pmxcfs improperly precess hostname specified in /etc/hostname. It resolves only only first part of your hostname before the dot.
    For instance, if your hostname is node7.vds.hoster.net then pmxcfs will attempt to resolve node7 ip address.
     
    imz likes this.
  15. imz

    imz New Member

    Joined:
    Dec 23, 2016
    Messages:
    1
    Likes Received:
    0
    Quite inconvenient! If they used the whole hostname, it would resolve without these troubles (thanks to libnss-mymachine, for instance).

    I wonder what was the reason to break the resolving by taking just the first part...

    Any plans to modify and improve this code?
     
  16. pas9x

    pas9x New Member

    Joined:
    Oct 23, 2016
    Messages:
    2
    Likes Received:
    1
    You can just put first part of your domain and ip into /etc/hosts file.

    It's hardly. This technique used in many other parts of proxmox software. So, complex code refactoring and essential architecture changes need to fix it. I think it is basic flaw in software architecture. I doubt that developers has motivation to do it :)
     
  17. maYer

    maYer New Member

    Joined:
    Apr 4, 2012
    Messages:
    16
    Likes Received:
    0
    i was writing FUD - removed it.

    In the end, the debian installer created a FQDN entry in hostname 127.0.0.1 with a vagrant domain, while the chef hostname recipe created one with <LANIP> real FQDN, the point is, since the hostname was the same in both cases, but not the FQDN, pve-cluster picks up the wrong one and fails to start.

    Ensure, obviously, that pve-cluster can only resolve the hostname to one, the valid FQDN using the hosts file
     
    #17 maYer, Aug 28, 2017
    Last edited: Aug 28, 2017

Share This Page