# Remove the default user Pi

**URL:** <https://community.zymbit.com/t/remove-the-default-user-pi/723>\
**Category:** ZYMKEY4\
**Created:** [February 5, 2020, 5:58am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723 "2020-02-05T05:58:20Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![Albert](https://avatars.discourse-cdn.com/v4/letter/a/48db29/32.png) [@Albert](https://community.zymbit.com/u/Albert)\
**Post date:** [February 5, 2020, 5:58am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/1 "2020-02-05T05:58:20Z")

</div>

I have zymbit key setup with Luks encryption in Raspberry Pi 3 Model B+ with Rasbian Buster OS. This works without problem but when I remove the the default raspberry user Pi and added my own root user the zymbit key will not bind (light blinking rapidly) but the OS still boot with the encrypted volume.

I need to remove the default user Pi. How do I get this to work ?

---

<div class="post-metadata">

**Author:** ![grundyoso](https://yyz1.discourse-cdn.com/flex027/user_avatar/community.zymbit.com/grundyoso/32/258_2.png) [@grundyoso](https://community.zymbit.com/u/grundyoso)\
**Post date:** [February 5, 2020, 7:00am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/2 "2020-02-05T07:00:34Z")

</div>

Hi Albert, this doesn’t sound right as I’m doing the same thing and it’s been working for me for few months now across many units. Are you sure you’re running Phase 1 and Phase 2 from the `root` account (via sudo)… In my case I `sudo su` to gain `root` terminal for all the zymkey setup stuff…

hope this helps,  
Richard

---

<div class="post-metadata">

**Author:** ![Albert](https://avatars.discourse-cdn.com/v4/letter/a/48db29/32.png) [@Albert](https://community.zymbit.com/u/Albert)\
**Post date:** [February 5, 2020, 7:58am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/3 "2020-02-05T07:58:40Z")

</div>

I guess that could be the root cause of the problem not doing a sudo su but using pi to install and then adding a new user and removing pi is a no go.

I suggest zymbit put a **font size 42 bold** on the need to install the package via **sudo su** wasted a few hours on why it does not work.

---

<div class="post-metadata">

**Author:** ![Bob\_of\_Zymbit](https://avatars.discourse-cdn.com/v4/letter/b/82dd89/32.png) [@Bob\_of\_Zymbit](https://community.zymbit.com/u/Bob_of_Zymbit)\
**Post date:** [February 6, 2020, 6:12pm UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/4 "2020-02-06T18:12:55Z")

</div>

We’ve had no issues with this in our testing. Scripts install fine using instructions as per getting started/encryption guide. Removing pi user and making a new user is a mutually exclusive operation that has no bearing on zymkey components.

Which version of Raspbian are you using? Desktop or lite?

---

<div class="post-metadata">

**Author:** ![Albert](https://avatars.discourse-cdn.com/v4/letter/a/48db29/32.png) [@Albert](https://community.zymbit.com/u/Albert)\
**Post date:** [February 7, 2020, 12:25am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/5 "2020-02-07T00:25:47Z")

</div>

The initial install of Zymbit software is as follows:

1. Burn the Raspbian Buster image to a SD (16GB) with ssh option (drop the file ssh in the boot partition)
2. Boot Raspberry Pi with the SD card
3. Login with the default user pi and password via ssh
4. install OS update and upgrade (sudo apt-get update and sudo apt-get upgrade)
5. Install Zymbit hardware and software as per instruction.
6. Install Zymbit Luks encryption as per instruction.
7. Change the username and password and reboot
8. Zymbit zkifc service is not loaded, even the zkifc.service is missing from the /lib/systemd/system directory.

Note: Rasbian Buster Lite version **September 2019**

---

<div class="post-metadata">

**Author:** ![root](https://yyz1.discourse-cdn.com/flex027/user_avatar/community.zymbit.com/root/32/395_2.png) [@root](https://community.zymbit.com/u/root)\
**Post date:** [February 7, 2020, 1:27am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/6 "2020-02-07T01:27:27Z")

</div>

Will Zymbit work with all Linux distributions on Pi 4 or only Raspbian?

---

<div class="post-metadata">

**Author:** ![Bob\_of\_Zymbit](https://avatars.discourse-cdn.com/v4/letter/b/82dd89/32.png) [@Bob\_of\_Zymbit](https://community.zymbit.com/u/Bob_of_Zymbit)\
**Post date:** [February 7, 2020, 6:29am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/7 "2020-02-07T06:29:26Z")

</div>

The first attempt to convert the SD card requires 2 reboots which are done automatically. Are you sure that you have been through both reboot cycles? The fact that zkifc.service is missing looks like you have ssh’ed in during the second reboot cycle.

Another question is: how are you changing the username and password? `sudo adduser <newuser>` followed by `sudo deluser pi`?

---

<div class="post-metadata">

**Author:** ![Bob\_of\_Zymbit](https://avatars.discourse-cdn.com/v4/letter/b/82dd89/32.png) [@Bob\_of\_Zymbit](https://community.zymbit.com/u/Bob_of_Zymbit)\
**Post date:** [February 7, 2020, 6:31am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/8 "2020-02-07T06:31:02Z")

</div>

We currently support Raspbian Buster and Ubuntu 18.04 x64. In theory, either of these repos may line up with other Debian derived distros.

Is there a particular distro you’re interested in?

---

<div class="post-metadata">

**Author:** ![Albert](https://avatars.discourse-cdn.com/v4/letter/a/48db29/32.png) [@Albert](https://community.zymbit.com/u/Albert)\
**Post date:** [February 7, 2020, 7:04am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/9 "2020-02-07T07:04:33Z")

</div>

I have done that 5 different times. If i do not change the user name it works perfectly. I can do a reboot cycle 10 times in a row without problem. The zkifc service will be missing after reboot when the default pi user name is changed.

---

<div class="post-metadata">

**Author:** ![Bob\_of\_Zymbit](https://avatars.discourse-cdn.com/v4/letter/b/82dd89/32.png) [@Bob\_of\_Zymbit](https://community.zymbit.com/u/Bob_of_Zymbit)\
**Post date:** [February 7, 2020, 7:49am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/10 "2020-02-07T07:49:08Z")

</div>

@Albert From above:

> Another question is: how are you changing the username and password? `sudo adduser <newuser>` followed by `sudo deluser pi`?

---

<div class="post-metadata">

**Author:** ![Albert](https://avatars.discourse-cdn.com/v4/letter/a/48db29/32.png) [@Albert](https://community.zymbit.com/u/Albert)\
**Post date:** [February 8, 2020, 6:27am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/11 "2020-02-08T06:27:46Z")

</div>

Well I am using the following commands

sudo passwd root  
logout  
usermod -l newname pi  
usermod -m -d /home/newname newname  
passwd  
sudo apt-get update  
sudo passwd -l root

---

<div class="post-metadata">

**Author:** ![Bob\_of\_Zymbit](https://avatars.discourse-cdn.com/v4/letter/b/82dd89/32.png) [@Bob\_of\_Zymbit](https://community.zymbit.com/u/Bob_of_Zymbit)\
**Post date:** [February 9, 2020, 5:57am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/12 "2020-02-09T05:57:35Z")

</div>

OK, thanks. We’ll give that a try here.

---

<div class="post-metadata">

**Author:** ![Bob\_of\_Zymbit](https://avatars.discourse-cdn.com/v4/letter/b/82dd89/32.png) [@Bob\_of\_Zymbit](https://community.zymbit.com/u/Bob_of_Zymbit)\
**Post date:** [February 11, 2020, 2:06am UTC](https://community.zymbit.com/t/remove-the-default-user-pi/723/13 "2020-02-11T02:06:05Z")

</div>

@Albert  
I am seeing no issues. For reference, I am using the latest release of Raspbian Buster dated Feb 5, 2020 (2020-02-05). Also, I updated/upgraded to the latest before starting the Zymkey installation and the encryption script.

Then, I performed your steps with modifications in **bold** :

1. sudo passwd root
2. logout
3. **login as pi**
4. **sudo** usermod -l newname pi
5. **sudo** usermod -m -d /home/newname newname
6. passwd
7. sudo apt-get update
8. sudo passwd -l root
