I thought I could clone a running CentOS 7.7 installation by replicating the contents of the /, /boot, /boot/efi partitions on the target disk and then modifying the /etc/fstab and the grub.cfg files to allow for the UUID changes. Evidently there is something I am missing since the cloned disk boots up OK except for login processing. The tigerVNC server has been successfully cloned and I can remotely login to the cloned installation. The symptoms are I don’t get the usual login prompt on the main console, and when I try to login with ssh, I am prompted for the user id and then the password, but when I enter the password I get the response back “/bin/bash: Permission denied.” Similarly, when I boot to run level 3, after entering the password it loops back to the login: prompt. So, most everything is working except for password authentication. Relevant output from journalctl are:

systemd-logind[681]: Failed to start user slice user-42.slice, ignoring: Access denied (org.freedesktop.DBus.Error.AccessDenied)

systemd-logind[681]: Failed to start session scope session-c1.scope: Access denied

gdm-launch-environment][1499]: pam_systemd(gdm-launch-environment:session): Failed to create session: Access denied

gdm-launch-environment][1499]: pam_unix(gdm-launch-environment:session): session opened for user gdm by (uid=0)

Querying systemd-logind status returns “active (running)” and also says “Started Login Service”

I will appreciate any idea on what it is that I have overlooked.

2 Answers 2


Clonezilla is capable of cloning the whole disk to another disk. I think that's what you need in this case.

  • I appreciate your answer. On the other hand, I want to understand what it is that I have missed. One other thing I discovered since I asked my question is, if I disable selinux in /etc/selinux/config, then all the login issues go away. I would like to understand why though. I had used the tar utility's --selinux option to make a copy of the root filesystem to be cloned (the root filesystem that tar ran against was not the booted root filesystem; it was mounted only fro the tar to run).
    – ORAY
    Commented Jan 27 at 19:30

Even though I entered the --selinux option of the tar command while I was creating the tar file of the root filesystem to be cloned, I had failed to enter the --selinux option while I was un-tarring onto the target disk.

Fixing this resulted in successfully cloning the disk.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .