LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 03-12-2020, 01:43 AM   #1
!!!
Member
 
Registered: Jan 2017
Location: Fremont, CA, USA
Distribution: Trying any&ALL on old/minimal
Posts: 997

Rep: Reputation: 382Reputation: 382Reputation: 382Reputation: 382
Question Any way to ADD persist{a,e}nce to *RUNNING* Live USB Ubuntu (19.04)? NO casper-rw present.


I'm RUNNING live and want to SAVE some stuff I've done (install sysdig)
(Meaning: I don't want to reboot!!! btw, I'm not sure how USB was written [by someone else], sorry)

Is it possible? Hints? (or cookbook!)

I spelled it wrong {a} and found:
https://askubuntu.com/questions/9558...ble-flashdrive
I then spelled it correctly {e} and found a bunch of obscure stuff...

There are 191 casper files, like /etc/casper.conf /var initramfs-tools ...
(but NO casper-rw)

Here's some output:
Code:
ubuntu@ubuntu:~$ sudo updatedb; locate casper-rw
ubuntu@ubuntu:~$ sudo fdisk -l /dev/sdb
Disk /dev/sdb: 14.4 GiB, 15483273216 bytes, 30240768 sectors
Disk model: DataTraveler 2.0
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x46f8e7bf

Device     Boot   Start     End Sectors  Size Id Type
/dev/sdb1  *          0 4095999 4096000    2G  0 Empty
/dev/sdb2       4066772 4074259    7488  3.7M ef EFI (FAT-12/16/32)
ubuntu@ubuntu:~$ df|grep sdb
/dev/sdb         2048000  2048000         0 100% /cdrom
uname-a: Linux ubuntu 5.0.0-13-generic #14-Ubuntu SMP Mon Apr 15 14:59:14 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Netbook: ASUS eeePC 1005PE

P.S. Obviously, there's a LOT I don't know about persistence,
(and [YUMI!!! but not this one] 'live' pendrives),
so I ask patience!!! Thanks In Advance!!! Tutorial links welcome!!!

p.p.s.:
Found (from 1st 'Similar Threads' at BOTTOM of page) and am reading:
https://help.ubuntu.com/community/LiveCD/Persistence

valnar (last Similar): "Loopback/casper files don't allow for full upgradability and would overflow on an apt-get update."
Huh? Isn't that ONLY from making casper-rw partition too small? I've got 10+GB free

Last edited by !!!; 03-12-2020 at 02:07 AM. Reason: ps & pps
 
Old 03-12-2020, 03:43 AM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,750

Rep: Reputation: 5929Reputation: 5929Reputation: 5929Reputation: 5929Reputation: 5929Reputation: 5929Reputation: 5929Reputation: 5929Reputation: 5929Reputation: 5929Reputation: 5929
I don't think it is possible. Even if you could add a Casper-rw file/partition you would not be able to use it until you reboot.

In order to modify the USB drive you would need to unmount and that isn't possible unless the system is running entirely from RAM. Currently the system views the drive basically as a cdrom device which is read only and since it is in use, locked.

If the drive is using syslinux to boot the filesystem is vfat which is limited to 4GB files hence the limitation. Casper-rw partitions are a linux ext filesystem and don't have that limitation.

I don't think a running system will actually see the casper-rw file. If using one the it would be a boot option
cat /proc/cmdline

Last edited by michaelk; 03-12-2020 at 04:30 AM.
 
1 members found this post helpful.
Old 03-12-2020, 07:36 AM   #3
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 10,541

Rep: Reputation: 2496Reputation: 2496Reputation: 2496Reputation: 2496Reputation: 2496Reputation: 2496Reputation: 2496Reputation: 2496Reputation: 2496Reputation: 2496Reputation: 2496
Quote:
I'm RUNNING live and want to SAVE some stuff I've done (install sysdig)
(Meaning: I don't want to reboot!!!
That would come under the category of poor planning. Reading/research on the subject prior to using and installing software would have been helpful. It won't work the way you want but using another Linux system to shrink the 'live' os partition and then create a casper-rw partition of any size formatted with a Linux filesystem is pretty simple.
 
  


Reply

Tags
persistence



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] casper-rw file is taking up all the space on my USB backup coderlen Linux - Newbie 4 09-19-2018 03:44 PM
Changes to persistent Live USB don't persist eco_bach Linux - Newbie 4 12-30-2016 03:48 PM
Changing OpenOffice config file in Casper of Mint flash USB jimwg Linux - General 3 05-03-2012 05:31 PM
How to persist boot messages on USB live image? csharpp Fedora 3 09-28-2010 03:33 AM
Linux distro that is USB install friendly without a loopback/casper? valnar Linux - Newbie 5 02-05-2010 05:13 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 12:06 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration