Kali Linux 2018 Live USB with Persistence

Guide: Kali Linux 2020 & 2019 Live USB with Persistence (Windows)

Last updated on

In this guide we will create a Kali Linux 2020 Live USB from Windows and configure a persistent partition so we can retain files and settings between reboots. This guide also works with Kali Linux 2019 & 2018.

If you want persistence with encryption, please see: Guide: Kali Linux 2020 & 2019 Live USB with Encrypted Persistence (Windows)

1. Download Kali Linux 2020 (Live)

In this guide we are using the Kali Linux 64-Bit (Live) image, though it should work fine with the 32 Bit image as well. This guide also works with Kali Linux 2019 and Kali Linux 2018.

2. Write Kali Linux 2020 Live ISO to USB

Write the ISO to your USB drive using a tool like Universal USB Installer or UNetbootin. In this guide we are using Universal USB Installer.

  1. Run Universal USB Installer.
  2. Select Kali Linux from the dropdown menu. (Kali is listed under Security and Penetration Testing).
  3. Browse for the Kali Linux 2020 Live ISO you downloaded.
  4. Select your USB drive from the drowpdown menu.
  5. Now select the checkbox Fat32 Format Drive (Erases Content).
  6. Finally, click Create.

It may take a few minutes to write Kali Linux 2020 Live ISO to USB.

Creating a Kali Linux Live USB with Universal USB Installer

3. Resize USB Partition

Now that your Kali Linux 2020 ISO has been written to your USB drive, we can begin setting up partitions to work with Kali Live Persistence. You can configure partitions with the partition manager of your choice, but in this guide we are going to use MiniTool Partition Wizard

When installing Partition Wizard, make sure to uncheck the checkbox on the Avast screen – you don’t need to install that.

Once installed, run and select Disk and Partition Management.

MiniTool Partition Wizard - Disk and Partition Management

Right-click on the blue disk space bar of your USB drive and click Move/Resize. In the example below, the USB drive is Disk 3 and it has a blue USB icon over it.

Resize the partition to 4GB and click OK. This is the partition where the Kali Linux system files reside and shouldn’t ever need more than 4GB.

4. Create Persistence Partition

We will now create the persistence partition, which will store your personal files and Kali settings.

Right-click on the Unallocated partition and click Create.

Click Yes if you see a message “The new created partition cannot be used in Windows. Because Windows could only recognize the first partition on a removable disk. Do you want to continue?”

In the File System dropdown, select EXT4.

In the Partition Label field, enter persistence. It’s important that you spell this correctly.

Use the maximum partition size available (or the size of your choice) and click OK.

Finally, click Apply in the top left-hand corner and click Yes to apply changes.

The Partition Wizard will now set up your partitions. This may take some time depending on the size of your USB drive.

Once done, close Partition Wizard and safely eject your USB drive.

5. Boot Into Kali 2020 Live USB

To boot from USB in most modern PCs, hold down the shift key while clicking Restart in the Windows start menu. If this doesn’t work, you may need to do some searching on how to boot from USB on your particular machine. Repeatedly pressing one of the function keys (F12F2, etc) or the ESC or Delete keys on bootup will invoke the boot or BIOS menus on some machines.

In the Kali boot menu, select Live system (persistence, check kali.org/prst) and press Enter. The menu may look slighly different depending on your version of Kali.

Kali should boot straight to Desktop. However, if you do get a password prompt, the default username and password in Kali Linux 2020 is “kali”. For Kali Linux 2019 and below, the default user is “root” and the password is “toor”.

6. Mount Persistence Partition

Once Kali has booted, we will use fdisk to view the disk devices and partitions.

Open a new terminal window and run:

sudo fdisk -l

You will see several entries for partitions and devices listed. Look for your USB drive. It will have two partitions: A 4GB partition and a persistence partition you created earlier. The persistence partition should appear as Linux under the Type column.

Device     Boot    Start       End   Sectors   Size Id Type
/dev/sdb1           2048   8390655   8388608     4G  c W95 FAT32 (LBA)
/dev/sdb2        8390656  30463999  22073344  10.5G 83 Linux

In the above example, we can see the USB drive with a 4GB partition and a larger persistence partition with the device name sdb2. This device name may be different on your setup. Make sure you have the right one before continuing.

Assuming your persistence partition device name is sdb2, run the following commands.

IMPORTANT: You must enter these commands exactly and ensure you choose the correct device (yours may not be sdb2), otherwise persistence will not work.

Create a new mount point called my_usb.

sudo mkdir -p /mnt/my_usb

Mount your USB persistence partition to my_usb. Reminder: Your persistence partition may not be sdb2, please ensure you mount the right one.

sudo mount /dev/sdb2 /mnt/my_usb

Create a new file called persistence.conf using the nano text editor.

sudo nano /mnt/my_usb/persistence.conf

In this file, type / union.

/mnt/my_usb/persistence.conf
/ union

Save the file and exit. (Press CTRL + X, press Y, then press ENTER).

Now unmount your persistence partition. Reminder: Your persistence partition may not be sdb2, please ensure you unmount the right one.

sudo umount /dev/sdb2

We’re done!

Restart the machine, boot from USB again, and from now on always select Live system (persistence, check kali.org/prst)

To test if persistence is working correctly, try creating an empty test folder on the Desktop and restarting. Select Live system (persistence, check kali.org/prst) again and if the test folder is still there, persistence is working correctly.

1 Star2 Stars3 Stars4 Stars5 Stars 4.53 (95 votes)

Let me know if this helped. Follow me on Twitter, Facebook and YouTube, or 🍊 buy me a smoothie.

p.s. I increased my AdSense revenue by 68% using AI 🤖. Read my Ezoic review to find out how.

198 replies

avatar
  Subscribe  
newest oldest
Notify of
Malc
Guest
Malc
Malc
11 days ago

great uttorial thanks. Clear consise and straightforward. Only thing to add is that on point 6. Sudo fdisk -l looks like number 1 and its it’s a lower case ‘L’ Must be the font

Snowden
Guest
Snowden
Snowden
27 days ago

Thank you, God Bless you!

vishv
Guest
vishv
vishv
1 month ago

sir i made a kali live usbe before and now im here pls answer my questions

i have not made any persistence will it work with that
lucky
Guest
lucky
lucky
1 month ago

hey I have got a problem actually its not saving the file after reboot. Help!!!!!

Johnny
Guest
Johnny
Johnny
1 month ago

It works very well, thank you!

I made one mistake: Naming the partition of the USB stick “Persistence” instead of “persistence”. The capital letter ruined it the first time I tried. 😉

HaxNet
Guest
HaxNet
HaxNet
1 month ago

This broke my 256GB usb. Now my USB isn’t being recognized at all. This happened during or after the Mini Partition Tool.

Can’t fix my USB. Or this is only good with like a 32GB or smaller thumbdrive?

NoxFlek
Guest
NoxFlek
NoxFlek
1 month ago

bro google how to clear n usb and how to delete all partisions using cmd

A person who put in a fake email
Guest
A person who put in a fake email
A person who put in a fake email
1 month ago

Use Minitool and Format it

Ishu
Guest
Ishu
Ishu
1 month ago

Bro use refus for format ✌️
Your pendrive will be formatted

Razvan
Guest
Razvan
Razvan
1 month ago

Hello !

[FAILED] Failed unmounting /run/live/persistence/sdc1
[FAILED] Failed unmounting /tmp

I used Kali before on another laptop and persistence worked now with v2020.2 i can run live but when i try to go into persistence
i get this errors and it shutsdown after 1min

any susugestions ?

Ayuba Nazeer
Guest
Ayuba Nazeer
Ayuba Nazeer
2 months ago

Hello
I’m trying the live persistence for the first time.
Follow all relevant procedures and steps, but still not working and my screen contd turning upside down I.e the opposite way
Please need your assistance urgently.

Thanks

Khan
Guest
Khan
Khan
2 months ago

Sir I am not able to connect my Kali Linux with my wifi.
And live persistence is also not working.
When restart the pc than it removes my folders which I created earlier.
Plz help me

jhon
Guest
jhon
jhon
2 months ago

try ifconfig
and lsusb

Samip Shah
Guest
Samip Shah
Samip Shah
1 month ago

Make sure you have space in between / and union like / union. I followed the same mistake and learnt a hard way.

command should be :

correct format
echo “/ union” > your mounted path ex. /mnt/usb

incorrect format
echo “/union” > your mounted path ex. /mnt/usb

zak
Guest
zak
zak
3 months ago

hi,
thx a lot for this tutorial, it was very clear and usefull
may god bless you,
salam 🙂

Abhi
Guest
Abhi
Abhi
3 months ago

Its storing the forders but if I change the passwd of the user if I restart its not changing to login to that user I should default password only.

Abhi
Guest
Abhi
Abhi
3 months ago

Its storing the forders but if I change the passwd of the user if I restart its not changing to login to that user I should use default password only.

Aryan
Guest
Aryan
Aryan
3 months ago

I have done dist upgrade in kali 2020.1 live but after reboot it shows black screen only . What’s the problem here and how to install upgraded tools .

Adharsh G Raju
Guest
Adharsh G Raju
Adharsh G Raju
3 months ago

Hey,
I tried the live usb version on my pc as well as laptop. It worked perfectly on pc which runs on intel i3 processor. But on my laptop, sometimes it shows only blank screen. Even if it boots into the window, there is some graphical/display error whenever i point to any folders or options like blurry color pattern. My laptop runs on Amd ryzen 5. Please help to sort this out. I tried updating drivers. Still no use.

Sagitta
Guest
Sagitta
Sagitta
3 months ago

Thanks G

R K Jain
Guest
R K Jain
R K Jain
3 months ago

Hey thanks for this advice. I made a bootable usb with kali linux 2020.1, I followed these instruction for mounting partition with persistence.conf and unmounted after \ union line added to persistence.conf. after reboot my test folder was missing so this did not work for me. My partition is sdb2 as well… first partition is fat32 lba second is not linux though. Used easy2boot software.

Jason Lynd
Guest
Jason Lynd
Jason Lynd
3 months ago

I labeled the partition with both Rufus and the mini-tool of witch I prefer Rufus but it did not save properly and I had to run the command mentioned in the comments to name the partition and success! e2label /dev/sdb2 persistence

Olexander
Guest
Olexander
Olexander
3 months ago

I can’t set “Live system persistence (2020)”. It have always broken, when I tried to launch it and I had 2 ERRORS: “Failed unmounting /run/live/persistence/sdb5” and “Failed unmounting /tmp.”

Gina Popa
Guest
Gina Popa
Gina Popa
4 months ago

Hi! Easy to understand for a newbie, Great job!
I did all the steps, but the folder isn’t there after restart, the persistence.conf file is saved and all but no folder.
I did encounter this messege on red after sudo fdisk -l:
partition 1 does not start on physical sector boundry. It could be this the problem?
Thanks a lot!

Scott
Guest
Scott
Scott
4 months ago

Same issue. Partition is there and persistence.conf is in the unmounted partition but no saved file or folder on the desktop.

Scott
Guest
Scott
Scott
4 months ago

Figured it out directly from the kali.org website. You need to label the partition “persistence”. The OS must look for that when loading the live boot. If you’ve followed the guide completely and still don’t have a persistent boot, while the partition is unmounted (not sure it makes a difference, but just what i did) in the terminal type “e2label /dev/sdb2 persistence”. Per the guide and comments, “sdb2” in the command will be whatever your partition is actually labeled from fdisk -l command. Labeling the partition persistence fixed the issue for me and now I have a persistent boot.

Don Joseph
Guest
Don Joseph
Don Joseph
4 months ago

Thank You Man.
I have been looking for this for the past couple of weeks.
Done a great job.

Jonny
Guest
Jonny
Jonny
4 months ago

If this don’t work, change Step 4. Create.
Set your new presistence partition NOT as Primary but as Logical. Now everything works 🙂

On your Screenshot (comment image ) it looks like a lighter blue, so do you used Logical too?

Sorry for my bad english…

kopl
Guest
kopl
kopl
5 months ago

How do I make persistence the default boot option, anyone?

fkface
Guest
fkface
fkface
4 months ago

I dont have the exact method, but try searching “Edit grub2 boot options”

Eugene
Guest
Eugene
Eugene
5 months ago

[email protected]:~$ sudo mkdir -p /mnt/my_usb
[email protected]:~$ sudo mount /dev/sdb2 /mnt/my_usb
[email protected]:~$ sudo echo “/ union” > /mnt/my_usb/persistence.conf
bash: /mnt/my_usb/persistence.conf: Permission denied

After step with “echo…” i had bloker with “Permission deined”
I already try to use:
sudo sh -c “echo “/ union” > /mnt/my_usb/persistence.conf” and the result was:
[email protected]:~$ sudo sh -c “echo “/ union” > /mnt/my_usb/persistence.conf”
/
I had just “/” as result of my command. Then i create new folder on the Desktop to check if this changes will save. Restart PC, go Kali Linux Live with Persistence – my folder did not saved..

Do you know what the reason and how could fix this behavior??

mihnea
Guest
mihnea
mihnea
5 months ago

Log in as root and then redo the procedure ( it should work better than sudo), kali 2020 logs in as non-root by default

Rajnine
Guest
Rajnine
Rajnine
5 months ago

how can I log in as root kali 202 got rid of root default?

mihnea
Guest
mihnea
mihnea
5 months ago

you can also use
sudo -i

Mystic
Guest
Mystic
Mystic
5 months ago

Everything is followed as guided through, but the persistence isn’t working in Kali’s settings or folder creation in the desktop – as soon as i restart it goes back to original, Kali Version is 2019.4 – it does save the folder in the encrypted partition though, but nothing settings wise or let’s say if i update or upgrade nothing gets saved after restart – please help?

JimV
Guest
JimV
JimV
5 months ago

echo “/ union” >/mnt/my_usb/persistence.conf

Teja Varma
Guest
Teja Varma
Teja Varma
7 months ago

I booted successful but there’s a small error “failed to set keymap” I that a problem

Sean
Guest
Sean
Sean
8 months ago

I followed instructions and partitioned usb correctly. After booting into live w/ persistence i entered the remaining commands. The first three went fine but the fourth not so much. How do i correct this?

mkdir -p /mnt/my_usb

mount /dev/sdb3 /mnt/my_usb

echo “/ union” > /mnt/my_usb/persistence.conf

umount /dev/sdb3

Umount: /dev/sbd3: no such mount point specified

Dan Snider
Guest
Dan Snider
Dan Snider
7 months ago

Try umount /mnt/my_usb instead.

Scott
Guest
Scott
Scott
4 months ago

“umount: /mnt/my_usb: target is busy.”

cliftz
Guest
cliftz
cliftz
8 months ago

**newest kali linux build on 512 gig usb device. used YUMI multiboot. Followed your above directions and also read the comments. Took over 8 hours to complete. Didn't make a test folder. Rather took a screenshot of terminal window. After restarting, I'm getting a failed to set font and keymap…(hmm, that doesn't sound too serious). Booted up, but the image of the terminal window wasn't in Pictures folder. Shut the windows machine down and re-started from usb again. Still no picture. Anyhow, then used sudo systemctl restart console-setup.service. Saved that command on a text and saved to documents. Also, put a Folder on the Desktop. Rebooted into the Windows. Then shut down and booted into Kali (from the usb). When it started this time, the folder is on the Desktop and the saved text is in the Documents folder. So, it's working. Still trying to figure out the "failed to set console font and keymap" at start-up. Thank you for your time. I'll take it from here. 🙂 Have to search out some more of your stuff… cheers

intstuan
Guest
intstuan
intstuan
9 months ago

I tried both kali-linux-large-2019.3-amd64.iso and kali-linux-2019.3-i386.iso in 2 different 8GB USB. I followed step by step
/dev/sdc1 4.7G c W95 FAT32 (LBA)
/dev/sdc2 2.8G 83 Linux

mkdir -p /mnt/my_usb
mount /dev/sdc2 /mnt/my_usb
echo “/ union” >/mnt/my_usb/persistence.conf
umount /dev/sdc2

but it didn’t work well.
Pls help.

Nadda Picard
Guest
Nadda Picard
Nadda Picard
9 months ago

I tried your way twice, with the 2018 and 2019 Kali version, and both worked well. This is an excellent guide!

Actually, the second time I wanted to use a different way. I am using Rufus to create Live USB, and it allows creating persistent partition directly when writing the ISO. The partitions were created, but for some unknown reason, the persistent one got filled up very quickly. And I was left with 0 bytes left. I tried it twice, but the same thing happens, in no time I got 100% usage.

Then I try your way again. I let Rufus create Live USB with no persistent partition. Then resize the partition, and create persistence.conf manually. Until now, it got only 11% used and I already install so many more. I am still wondering, what when wrong, but I left the questions for a later time.

alex
Guest
alex
alex
9 months ago

nothing saves to the desktop ? 🙁

Ansh
Guest
Ansh
Ansh
6 months ago

same issue

Robert
Guest
Robert
Robert
10 months ago

Your a genius I got it persistence and everything, finally thank you again.

Robeet
Guest
Robeet
Robeet
10 months ago

I cant get Kali 2019.2 at all except for failsafe mode but you got me that far nothing else was working even near this well. I did get Kali 2019.1 to boot right up one problem though persistence isnt working could you please post how to fix that. Kali was kicking my ass but you got me going would be nice if I didnt have to start from go though every time I log on. One last thing some douche put in the comments about one of your commands being off the one that starts with echo. He’s nuts I typed it just as you had it and it worked perfectly. The second time I booted Kali I tried it his way hoping persistence might work it wont accept it his way. Would love it if you did something on a tool that actually works well for pentesting, been using Aircrack-ng and Hashcat on Unbuntu but man is it slow going. Thanks again and please if you can could you post how to get the persistence to work.

DattatreyaReddy Panta
Guest
DattatreyaReddy Panta
DattatreyaReddy Panta
10 months ago

Everything works well but when shutdowning it is not shutdowning at all
It is showing”a stop job is running”

A person who put a fake email
Guest
A person who put a fake email
A person who put a fake email
22 days ago

Try shutdown –force

Zoudan
Guest
Zoudan
Zoudan
11 months ago

Amazing, just trying it at the moment but this information was clear, updated and simple as it should be, thank you very much!!

Yasiek
Guest
Yasiek
Yasiek
11 months ago

My mistake (as English is not my first language) was that I misspelled PERSISTENCE… instead I wrote PREsistence… after I’ve fixed that it works.

Michael de France
Guest
Michael de France
Michael de France
11 months ago

Everything works IF you also do these things:

Remember that the OS might be bigger then 4GB. Adjust for that if needed.
Set your new presistence partition NOT as Primary but as Logical. (VERY IMPORTANT).
echo “/ union” > /mnt/my_usb/persistence.conf // ( > /mnt) this commando is wrong.

echo “/ union” >/mnt/my_usb/persistence.conf // ( >/mnt) this commando is right.

The diffrence is the space. (> /mnt…) –> (>/mnt…) as mentioned by Cristian Ritter in the comments below.

Other then that, nice tutorial!

Dave
Guest
Dave
Dave
11 months ago

I’m using a 32GB 3.0 flash drive, so I know that space isn’t an issue. I also increased the initial partition resize from 4 to 5 to see if that made any difference, but has not.

I missed the comment about the space in the command being incorrect, I will give that a shot. Thank you!

Terry
Guest
Terry
Terry
11 months ago

Well, I sure hope you are right. I can’t tell you how long I have trying to get this to work. It doesn’t seem to hard to do at all. But the system just won’t recognize the persistence partition what-so-ever. Thanks for the input on what to try,

Dave
Guest
Dave
Dave
11 months ago

I’ve followed the steps a few times with Kali 2019.2 and can’t seem to get anything to save. No errors in the commands, but nothing saves when I reboot.

icsaru
Guest
icsaru
icsaru
11 months ago

sdb1 is same of sda1? in my case the created empty folder not show after restar kali USB persistence.

Joshua
Guest
Joshua
Joshua
11 months ago

Mine kind of worked. I cant save a folder to the desktop, but it looks like a usb drive is mounted called persistence… Clearly I did something wrong. And tips?

Joshua Robertson
Guest
Joshua Robertson
Joshua Robertson
11 months ago

Can I set persistence and load nvidia drivers on any pc that uses an intel gpu, then be able to use that live usb with other pc’s with nvidia cards? Thank you very much

JimmyWilkins
Guest
JimmyWilkins
JimmyWilkins
1 year ago

when I used fdisk -l
I got an output that has the /dev/sdb2 as hpfs/ntfs/exFAT and not linux
then when I tried to mount /dev/sdb2 /mnt/my_usb it failed saying bad superblock on /dev/sdb2, missing codepage or helper program, or other error.

Any advice from here would be appreciated. I followed all of the steps above and one thing that happened that wasn’t covered was that it asked me to format the drive after I selected Apply at the end.

Eugene
Guest
Eugene
Eugene
1 year ago

Excellent! Thank you! I had a persistent partition before, but with your tutorial everything is persistent. Love it!

hussain
Guest
hussain
hussain
1 year ago

i exactly did what u have touhgt but i dont know where im mistaking

Samsung Smart Fridge
Guest
Samsung Smart Fridge
Samsung Smart Fridge
1 year ago

If you get an error say “bash : unmount command not found “ MAKE SURE YOU ARE SPELLING IT RIGHT ITS “umount” not “unmount”

Roshan
Guest
Roshan
Roshan
1 year ago

it worked bro thank you so much

Roshan
Guest
Roshan
Roshan
1 year ago

i followed same command as yours but not save changing…help me

Nayeem
Guest
Nayeem
Nayeem
1 year ago

Unmount /dev/sdb2 is not working

kad
Guest
kad
kad
1 year ago

umount and not unmount … 😉

Sakti
Guest
Sakti
Sakti
1 year ago

I have already followed this tutorial, but when everything is finished then I reboot the persistence again then a boot failure occurs (end trace ***********)

rikovgy
Guest
rikovgy
rikovgy
1 year ago

it gave me a error in minitool when i tried to do both commands at once so i split the tutorial and resized partition then apply and add new partition ext4 then applied all ran sweeet thanks

samrat
Guest
samrat
samrat
1 year ago

also provide how to recover your pen drive from bootable pen drive

Pourwant
Guest
Pourwant
Pourwant
1 year ago

I think so many people wrong when write command in terminal!!!

Suvan Balu
Guest
Suvan Balu
Suvan Balu
1 year ago

No im not having the folder after rebooting