View Issue Details

IDProjectCategoryView StatusLast Update
0005848Kali LinuxKali Websites & Docspublic2020-12-01 10:50
ReporterKaliMark Assigned ToGamb1t  
PrioritynormalSeverityminorReproducibilityalways
Status assignedResolutionopen 
Product Version2019.4 
Summary0005848: Documentation of Adding Persistence to a Kali Linux “Live” USB Drive is not working
Description

The documentation to create persistence leaves a few questions and requests for improvement, to make give some more background information for newbies to Kali and Linux.
To be honest: I am struggeling to create a persistent 32 GB drive based on the documentation.

In quotes you can find the current manual, I add my suggestions in single quotes. Hope this makes it easier to understand.
"you are running as the root user" > Suggestion: 'if you login the first time, you are the root user'

"your USB drive has a capacity of at least 8GB — the Kali Linux image takes over 3GB, and for this guide, we’ll be creating a new partition of about 4GB to store our persistent data in." > currently price for 8 GB drives are higher than 16 GB and many people just use 32 or more GB drive . As my stick has 32 GB, I am thinking about the minimum size of the Kali-Partition, as upgrades and additional tools also require some additional space. I would be happy, if the user could get some advice about the recommended size of each partition. My suggestion: adding a paragraph: 'Considerations on the size of the persistent partition: The Kali Linux image takes over 3 GB, for upgrades you will require additional xx GB, additional tools also require space. On 16 GB drives you should consider yy GB, above 32 GB you are good to go with zz GB.'

Step 1:
"This can be verified with the command “fdisk -l”." > > for Linux newbies it is not clear how to check this. I suggest to explain how to determine the position of the USB. I see the risk that otherwise on a desktop with several hard drives, someone will need Kali to repair the damage just caused. Suggestion 'The information on the disk, e.g. /dev/sdb, shoud match your stick in size and Disk model' >> Screenshot 1

Step 2: > I am lost here.
"First, let’s create the new partition in the empty space above our Kali Live partitions." > My Kali partition has only 2.6 G, which means not a lot of space for more tools. Wouldn't we first expand the partition to the recommended size mentioned above? As a second step I would use the rest or parts of it for persistence. Are there any suggestions available? Try and error is time consuming and I am willing to learn from others experience.

"end=7gb" > How is the end determined and what is the implication? The drive has 8 GB, why waste 1 gig? Which value should I enter using 16, 32 or more GBs? A suggestions would be great. Maybe an info how to use the whole stick?

"end=7gb
read start _ < <(du -bcm kali-linux-2019.4-amd64.iso | tail -1); echo $start
parted /dev/sdb mkpart primary $start $end"
Here my result: >> screenshot 2

My question: how does the Kali-image get on the stick? I guess that the new partition should start at the end of kali partition, right? How can I determine the exact position?
As I am coming from windows, I prefer GUIs to determine the correct harddrive. Can this also be explaind using gparted? For me it is very intuitive and similar to the windows manager.
I tried this way, but I have an issue with garted, as it doesn't show the drives >> screenshot 3. This is the first time I encounter this behaviour of gparted. Usually I am able to see the details of all drives. Any hint how to get full access?

Step 3 and 4 are afterwards strait forward.

Steps To Reproduce

I am following the instructions to add persistence to my newly created USB-drive: https://www.kali.org/docs/usb/kali-linux-live-usb-persistence/
I am root, the drive is /dev/sdb.
Entering the following commands:
end=7gb
read start _ < <(du -bcm kali-linux-2019.4-amd64.iso | tail -1); echo $start
parted /dev/sdb mkpart primary $start $end

Results: screenshot 2
root@kali:~# end=7gb
root@kali:~# read start _ < <(du -bcm kali-linux-2019.4-amd64.iso | tail -1); echo $start
du: cannot access 'kali-linux-2019.4-amd64.iso': No such file or directory
0
root@kali:~# parted /dev/sdb mkpart primary $start $end
Warning: You requested a partition from 0.00B to 7000MB (sectors 0..13671875).
The closest location we can manage is 512B to 32.3kB (sectors 1..63).
Is this still acceptable to you?
Yes/No?

gparted
selecting sdb: screenshot 3

Attached Files
Kazam_screenshot_00001.png (86,225 bytes)   
Kazam_screenshot_00001.png (86,225 bytes)   
Kazam_screenshot_00002.png (83,617 bytes)   
Kazam_screenshot_00002.png (83,617 bytes)   
Kazam_screenshot_00003.png (34,903 bytes)   
Kazam_screenshot_00003.png (34,903 bytes)   

Activities

Gamb1t

Gamb1t

2019-11-29 22:14

manager   ~0011492

These are really good points and I like your recommendations on the changes. Before getting into the different changes and questions you have posed for the doc, I want to be sure that you manage to get your persistent USB created. Have you been able to get it working yet?

KaliMark

KaliMark

2019-11-29 22:27

reporter   ~0011493

Nope :( I am stuck at this point. :-) I am browsing through some forums, but have not really a clue which busswords would bring up the right solution.
I played around with parted and was able to create a new partition between 20 gb an 25 gb by setting "parted /dev/sdb mkpart primary 20GB 25GB". I was able to see this with Win10, but still not with gparted.
I didn't test if on this partition persistence works.

Gamb1t

Gamb1t

2019-11-29 22:39

manager   ~0011494

Likely the best thing to do would create a new post to https://forums.kali.org/forumdisplay.php?13-Kali-Linux-TroubleShooting and we will be able to work together to get your persistence taken care of there. I have also created an issue on our GitLab, https://gitlab.com/kalilinux/documentation/kali-docs/issues/4. As our documentation is on GitLab we can now accept pull requests (merge requests) from users on potential changes, if you would like to try that out. https://www.kali.org/news/kali-linux-2019-4-release/

HiOnFruityPebbles

HiOnFruityPebbles

2019-11-30 23:23

reporter   ~0011502

https://www.pendrivelinux.com/universal-usb-installer-easy-as-1-2-3/ please give this usb writer a try, there is a slider that will help you set persistence, hope it works!

KaliMark

KaliMark

2019-12-01 11:08

reporter   ~0011503

1-2-3 does'nt really help... For Kali no persistence is offered. If persistence available, only 4 GB, which is on 32 GB a bit small. As a GUI might be helpful, it should also be possible using bash commands.

Issue History

Date Modified Username Field Change
2019-11-29 21:32 KaliMark New Issue
2019-11-29 21:32 KaliMark File Added: Kazam_screenshot_00001.png
2019-11-29 21:32 KaliMark File Added: Kazam_screenshot_00002.png
2019-11-29 21:32 KaliMark File Added: Kazam_screenshot_00003.png
2019-11-29 21:33 g0tmi1k Assigned To => Gamb1t
2019-11-29 21:33 g0tmi1k Status new => assigned
2019-11-29 22:14 Gamb1t Note Added: 0011492
2019-11-29 22:27 KaliMark Note Added: 0011493
2019-11-29 22:39 Gamb1t Note Added: 0011494
2019-11-30 23:23 HiOnFruityPebbles Note Added: 0011502
2019-12-01 11:08 KaliMark File Added: 2019-12-01 11_54_29-Universal USB Installer 1.9.8.9 Setup.png
2019-12-01 11:08 KaliMark File Added: 2019-12-01 12_05_28-Universal USB Installer 1.9.8.9 Setup.png
2019-12-01 11:08 KaliMark Note Added: 0011503
2020-12-01 10:50 g0tmi1k Severity major => minor