[Bug 1898081] [NEW] cephadm.postinst uses hard coded path /home/cephadm/

Uwe Richter 1898081 at bugs.launchpad.net
Thu Oct 1 16:59:57 UTC 2020


Public bug reported:

Hello all,

### release ###
lsb_release -rd
#Description:   Ubuntu 20.04.1 LTS
#Release:       20.04

### package version ###
apt-cache policy cephadm
#cephadm:
#  Installed: 15.2.3-0ubuntu0.20.04.2
#  Candidate: 15.2.3-0ubuntu0.20.04.2
#  Version table:
# *** 15.2.3-0ubuntu0.20.04.2 500
#        500 http://de.archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages
#        100 /var/lib/dpkg/status
#     15.2.1-0ubuntu1 500
#        500 http://de.archive.ubuntu.com/ubuntu focal/universe amd64 Packages

### expected ###
/var/lib/dpkg/info/cephadm.postinst using $HOME from previously created new user 'cephadm' to prepare ˜cephadm/.ssh/authorized_keys

### what happened instead ###
/var/lib/dpkg/info/cephadm.postinst uses hard coded path /home/cephadm complaining with
  "mkdir: cannot create directory ‘/home/cephadm/.ssh’: No such file or directory"
if /etc/adduser.conf:DHOME was modified.

### Notes ###
While installing cephadm(8) we get
  "mkdir: cannot create directory ‘/home/cephadm/.ssh’: No such file or directory"
due to hard coded "/home/cephadm/.ssh" in /var/lib/dpkg/info/cephadm.postinst .
Previously /var/lib/dpkg/info/cephadm.postinst uses adduser(8), honoring
/etc/adduser.conf:DHOME - which may be changed from it's default "/home".

Modified /var/lib/dpkg/info/cephadm.postinst attached.


Thanks & best regards
Uwe

** Affects: ceph (Ubuntu)
     Importance: Undecided
         Status: New

** Attachment added: "cephadm.postinst"
   https://bugs.launchpad.net/bugs/1898081/+attachment/5416238/+files/cephadm.postinst

-- 
You received this bug notification because you are a member of Ubuntu
OpenStack, which is subscribed to ceph in Ubuntu.
https://bugs.launchpad.net/bugs/1898081

Title:
  cephadm.postinst uses hard coded path /home/cephadm/

Status in ceph package in Ubuntu:
  New

Bug description:
  Hello all,

  ### release ###
  lsb_release -rd
  #Description:   Ubuntu 20.04.1 LTS
  #Release:       20.04

  ### package version ###
  apt-cache policy cephadm
  #cephadm:
  #  Installed: 15.2.3-0ubuntu0.20.04.2
  #  Candidate: 15.2.3-0ubuntu0.20.04.2
  #  Version table:
  # *** 15.2.3-0ubuntu0.20.04.2 500
  #        500 http://de.archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages
  #        100 /var/lib/dpkg/status
  #     15.2.1-0ubuntu1 500
  #        500 http://de.archive.ubuntu.com/ubuntu focal/universe amd64 Packages

  ### expected ###
  /var/lib/dpkg/info/cephadm.postinst using $HOME from previously created new user 'cephadm' to prepare ˜cephadm/.ssh/authorized_keys

  ### what happened instead ###
  /var/lib/dpkg/info/cephadm.postinst uses hard coded path /home/cephadm complaining with
    "mkdir: cannot create directory ‘/home/cephadm/.ssh’: No such file or directory"
  if /etc/adduser.conf:DHOME was modified.

  ### Notes ###
  While installing cephadm(8) we get
    "mkdir: cannot create directory ‘/home/cephadm/.ssh’: No such file or directory"
  due to hard coded "/home/cephadm/.ssh" in /var/lib/dpkg/info/cephadm.postinst .
  Previously /var/lib/dpkg/info/cephadm.postinst uses adduser(8), honoring
  /etc/adduser.conf:DHOME - which may be changed from it's default "/home".

  Modified /var/lib/dpkg/info/cephadm.postinst attached.

  
  Thanks & best regards
  Uwe

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ceph/+bug/1898081/+subscriptions



More information about the Ubuntu-openstack-bugs mailing list