Save.dat / changes confusion

Technical issues/questions of an intermediate or advanced nature.
Bogomips
Full of knowledge
Full of knowledge
Posts: 2564
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: Save.dat / changes confusion

Post#61 by Bogomips » 13 Aug 2016, 12:33

Jack wrote:I can tell you I'm lost on your last message. Is there a script you ca write that will help?
Only do this if you have a sdb2:
  • If you have sdb2 which format is it?
  • Script is already there. :wink: In last message go to CODE: SELECT ALL, clck on SELECT ALL, Ctl+C to copy, then go to terminal and paste at the prompt with Shift+Insert.
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

Jack
Contributor
Contributor
Posts: 1857
Joined: 09 Aug 2013, 14:25
Distribution: Porteus and Nemesis
Location: USA

Re: Save.dat / changes confusion

Post#62 by Jack » 13 Aug 2016, 15:36

I only have sda1,sd2 and sdb1. The sda1 and sda1 are Windows 7 and sdb1 is USB (Porteus OS). If I do any downloads I copy to sda2.
Script is already there. :wink: In last message go to CODE: SELECT ALL, clck on SELECT ALL, Ctl+C to copy, then go to terminal and paste at the prompt with Shift+Insert.
Which select all cause there 3 of them?
I just like Slackware because I think it teach you about Linux to build packages where Ubuntu is like Windows you just install programs you want.

Bogomips
Full of knowledge
Full of knowledge
Posts: 2564
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: Save.dat / changes confusion

Post#63 by Bogomips » 13 Aug 2016, 17:57

@ Jack

As you have specially made a usb for this testing, can you see if you are you able split it into 2 partitions? Use win$oze or linux, whichever easier. Then use win$oze make second partition NTFS?
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

Jack
Contributor
Contributor
Posts: 1857
Joined: 09 Aug 2013, 14:25
Distribution: Porteus and Nemesis
Location: USA

Re: Save.dat / changes confusion

Post#64 by Jack » 13 Aug 2016, 18:24

I will take the USB and try to split it in to 2 partition and format the 2nd partition ext4. If it don't work I will rebuild it. When done I will have a fat32 and ext4 partition.
EDIT:
I had to rebuild another USB. And I haven't ran the script yet. I will wait for you to tell in order what you want me to do.
I just like Slackware because I think it teach you about Linux to build packages where Ubuntu is like Windows you just install programs you want.

Bogomips
Full of knowledge
Full of knowledge
Posts: 2564
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: Save.dat / changes confusion

Post#65 by Bogomips » 13 Aug 2016, 18:48

Jack, when you have the sdb2 set up, make sure mksavfile.sh is in /home/guest directory, then just copy code from here to clipboard

Code: Select all

sh mksavfile.sh  porteussave.dat  256
sudo mkdir /mnt/sdb2/Test
sudo chmod  a+rw  /mnt/sdb2/Test
ls -ld /mnt/sdb2/Test
mv  porteussave.dat  /mnt/sdb2/Test
ls  -lh  /mnt/sdb2/Test/porteussave.dat
ls  -sh  /mnt/sdb2/Test/porteussave.dat
du -h  /mnt/sdb2/Test/porteussave.dat
open a terminal amd paste in at the prompt.
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

Jack
Contributor
Contributor
Posts: 1857
Joined: 09 Aug 2013, 14:25
Distribution: Porteus and Nemesis
Location: USA

Re: Save.dat / changes confusion

Post#66 by Jack » 13 Aug 2016, 19:12

I copy this from your post and it auto run when I pasted in terminal.

Code: Select all

sh mksavfile.sh  porteussave.dat  256
sudo mkdir /mnt/sdb2/Test
sudo chmod  a+rw  /mnt/sdb2/Test
ls -ld /mnt/sdb2/Test
mv  porteussave.dat  /mnt/sdb2/Test
ls  -lh  /mnt/sdb2/Test/porteussave.dat
ls  -sh  /mnt/sdb2/Test/porteussave.dat
du -h  /mnt/sdb2/Test/porteussave.dat
Here is the output and now should I reboot?

Code: Select all

guest@porteus:~$ ls
Desktop/  Documents/  Downloads/  Music/  Pictures/  Public/  Templates/  Videos/  mksavfile.sh*
guest@porteus:~$ sh mksavfile.sh  porteussave.dat  256
0+0 records in
0+0 records out
0 bytes copied, 0.000177746 s, 0.0 kB/s

ls -lh porteussave.dat
-rw-r--r-- 1 guest users 256M Aug 13 14:58 porteussave.dat

meta-data=porteussave.dat        isize=512    agcount=4, agsize=65536 blks
         =                       sectsz=512   attr=2, projid32bit=1
         =                       crc=1        finobt=1, sparse=0
data     =                       bsize=1024   blocks=262144, imaxpct=25
         =                       sunit=0      swidth=0 blks
naming   =version 2              bsize=4096   ascii-ci=0 ftype=1
log      =internal log           bsize=1024   blocks=2573, version=2
         =                       sectsz=512   sunit=0 blks, lazy-count=1
realtime =none                   extsz=4096   blocks=0, rtextents=0

file porteussave.dat
porteussave.dat: SGI XFS filesystem data (blksz 1024, inosz 512, v2 dirs)

ls -sh porteussave.dat
2.8M porteussave.dat
du -h porteussave.dat
2.8M	porteussave.dat

sudo mount porteussave.dat f2925
Password: 
Hold it up to the light --- not a brain in sight!
Password: 

du -sh f2925
0	f2925

df -h f2925
Filesystem      Size  Used Avail Use% Mounted on
/dev/loop15     254M  8.1M  246M   4% /home/guest/f2925
guest@porteus:~$ 
EDIT:
I just check sdb2 and Test directory is there and porteussave.dat is in side of test.
I just like Slackware because I think it teach you about Linux to build packages where Ubuntu is like Windows you just install programs you want.

Bogomips
Full of knowledge
Full of knowledge
Posts: 2564
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: Save.dat / changes confusion

Post#67 by Bogomips » 13 Aug 2016, 19:28

For some reason output from som statements did not show. Can you paste them in again please:

Code: Select all

ls  -lh  /mnt/sdb2/Test/porteussave.dat
ls  -sh  /mnt/sdb2/Test/porteussave.dat
du -h  /mnt/sdb2/Test/porteussave.dat
# Plus these:
mkdir f; sudo mount /mnt/sdb2/Test/porteussave.dat f;
du  -sh  f
df  -h  f
sudo umount f; rmdir f
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

Jack
Contributor
Contributor
Posts: 1857
Joined: 09 Aug 2013, 14:25
Distribution: Porteus and Nemesis
Location: USA

Re: Save.dat / changes confusion

Post#68 by Jack » 13 Aug 2016, 20:03

Bogomips wrote:For some reason output from som statements did not show. Can you paste them in again please:

Code: Select all

ls  -lh  /mnt/sdb2/Test/porteussave.dat
ls  -sh  /mnt/sdb2/Test/porteussave.dat
du -h  /mnt/sdb2/Test/porteussave.dat
# Plus these:
mkdir f; sudo mount /mnt/sdb2/Test/porteussave.dat f;
du  -sh  f
df  -h  f
sudo umount f; rmdir f
I copy and pasted in terminal and here the output.

Code: Select all

guest@porteus:~$ ls  -lh  /mnt/sdb2/Test/porteussave.dat
-rw-r--r-- 1 guest users 256M Aug 13 14:52 /mnt/sdb2/Test/porteussave.dat
guest@porteus:~$ ls  -sh  /mnt/sdb2/Test/porteussave.dat
2.1M /mnt/sdb2/Test/porteussave.dat
guest@porteus:~$ du -h  /mnt/sdb2/Test/porteussave.dat
2.1M	/mnt/sdb2/Test/porteussave.dat
guest@porteus:~$ # Plus these:
guest@porteus:~$ mkdir f; sudo mount /mnt/sdb2/Test/porteussave.dat f;
mkdir: cannot create directory ‘f’: File exists
Password: 
I don't wish to know that.
Password: 
guest@porteus:~$ 
I just like Slackware because I think it teach you about Linux to build packages where Ubuntu is like Windows you just install programs you want.

Jack
Contributor
Contributor
Posts: 1857
Joined: 09 Aug 2013, 14:25
Distribution: Porteus and Nemesis
Location: USA

Re: Save.dat / changes confusion

Post#69 by Jack » 13 Aug 2016, 20:16

If this is not right I don't know what else I can do. I wish other helping on this.
EDIT:
Could this be what you are looking for? I didn't copy it all.

Code: Select all

guest@porteus:~$ ls
Desktop/    Downloads/  Pictures/  Templates/  mksavfile.sh*
Documents/  Music/      Public/    Videos/
guest@porteus:~$ sh mksavfile.sh  porteussave.dat  256
0+0 records in
0+0 records out
0 bytes copied, 0.000155676 s, 0.0 kB/s

ls -lh porteussave.dat
-rw-r--r-- 1 guest users 256M Aug 13 14:52 porteussave.dat

mkfs.xfs: porteussave.dat appears to contain an existing filesystem (xfs).
mkfs.xfs: Use the -f option to force overwrite.

file porteussave.dat
porteussave.dat: SGI XFS filesystem data (blksz 1024, inosz 512, v2 dirs)

ls -sh porteussave.dat
3.6M porteussave.dat
du -h porteussave.dat
3.6M	porteussave.dat

sudo mount porteussave.dat f2347

du -sh f2347
0	f2347

df -h f2347
Filesystem      Size  Used Avail Use% Mounted on
/dev/loop15     254M  8.1M  246M   4% /home/guest/f2347
guest@porteus:~$ sudo mkdir /mnt/sdb2/Test
guest@porteus:~$ sudo chmod  a+rw  /mnt/sdb2/Test
guest@porteus:~$ ls -ld /mnt/sdb2/Test
drwxrwxrwx 2 root root 4096 Aug 13 14:52 /mnt/sdb2/Test/
guest@porteus:~$ mv  porteussave.dat  /mnt/sdb2/Test
guest@porteus:~$ ls  -lh  /mnt/sdb2/Test/porteussave.dat
-rw-r--r-- 1 guest users 256M Aug 13 14:52 /mnt/sdb2/Test/porteussave.dat
guest@porteus:~$ ls  -sh  /mnt/sdb2/Test/porteussave.dat
2.1M /mnt/sdb2/Test/porteussave.dat
guest@porteus:~$ du -h  /mnt/sdb2/Test/porteussave.dat
2.1M	/mnt/sdb2/Test/porteussave.dat
guest@porteus:~$ 
I just like Slackware because I think it teach you about Linux to build packages where Ubuntu is like Windows you just install programs you want.

Bogomips
Full of knowledge
Full of knowledge
Posts: 2564
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: Save.dat / changes confusion

Post#70 by Bogomips » 13 Aug 2016, 22:47

Jack wrote:If this is not right I don't know what else I can do. I wish other helping on this.
No problem Jack. You are coming along just fine.

Now you can reboot with changes=/dev/sdb2/Test/porteussave.dat. Need to keep on using the changes file until you think there has been plenty of changes gone in. Maybe if you download a small video, 20/30 MB, and check it is still in Downloads after you reboot.

Then
  • Reboot without using changes=
  • Run these commands in terminal

    Code: Select all

    ls  -lh  /mnt/sdb2/Test/porteussave.dat
    ls  -sh  /mnt/sdb2/Test/porteussave.dat
    du -h  /mnt/sdb2/Test/porteussave.dat
    [[ ! -e f ]] && mkdir f;
    mountpoint -q f && umount -f f;
    sudo mount /mnt/sdb2/Test/porteussave.dat f;
    du  -sh  f
    df  -h  f
    sudo umount f; rmdir f
    
Please post all the output, as we are trying to see if we can tell how much of the savefile has been used, and how much is still free to be used. Thanks.
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

Jack
Contributor
Contributor
Posts: 1857
Joined: 09 Aug 2013, 14:25
Distribution: Porteus and Nemesis
Location: USA

Re: Save.dat / changes confusion

Post#71 by Jack » 13 Aug 2016, 23:06

This didn't work changes=/dev/sdb2/Test/porteussave.dat so I change it to changes=/dev/sdb2/Test/porteussave.dat and still it didn't work.

Code: Select all

LABEL text
MENU LABEL Text mode
KERNEL vmlinuz
APPEND initrd=initrd.xz changes=/dev/sdb2/Test/porteussave.dat 3
TEXT HELP
    Run Porteus in text mode and
    start the command prompt only
ENDTEXT
Then this.

Code: Select all

LABEL text
MENU LABEL Text mode
KERNEL vmlinuz
APPEND initrd=initrd.xz changes=/mnt/sdb2/Test/porteussave.dat 3
TEXT HELP
    Run Porteus in text mode and
    start the command prompt only
ENDTEXT
I just like Slackware because I think it teach you about Linux to build packages where Ubuntu is like Windows you just install programs you want.

Jack
Contributor
Contributor
Posts: 1857
Joined: 09 Aug 2013, 14:25
Distribution: Porteus and Nemesis
Location: USA

Re: Save.dat / changes confusion

Post#72 by Jack » 13 Aug 2016, 23:42

I'm going to reboot my other USB I'll see you about this on Sun or Mon.
I just like Slackware because I think it teach you about Linux to build packages where Ubuntu is like Windows you just install programs you want.

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Re: Save.dat / changes confusion

Post#73 by Ed_P » 14 Aug 2016, 00:49

Bogomips wrote:@split it into 2 partitions? Use win$oze or linux, whichever easier. Then use win$oze make second partition NTFS?
FYI Windows doesn't support multiple partitions on removable drives. And FAT & exFAT are better formats for USB drives than NTFS.
Ed

Bogomips
Full of knowledge
Full of knowledge
Posts: 2564
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: Save.dat / changes confusion

Post#74 by Bogomips » 14 Aug 2016, 14:44

Ed, thanks for filling in the gaps in my win$oze knowledge. :)

@ Jack

When you put in the usb, please run these commands:

Code: Select all

file  /mnt/sdb2/Test/porteussave.dat
ls  -lh  /mnt/sdb2/Test/porteussave.dat
ls  -sh  /mnt/sdb2/Test/porteussave.dat
du -h  /mnt/sdb2/Test/porteussave.dat
[[ ! -e f ]] && mkdir f;
mountpoint -q f && umount -f f;
sudo mount /mnt/sdb2/Test/porteussave.dat f;
du  -sh  f
df  -h  f
sudo umount f; rmdir f
Also can you remember what the error message was that you got when you booted with changes=/dev/sdb2/Test/porteussave.dat?
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

Jack
Contributor
Contributor
Posts: 1857
Joined: 09 Aug 2013, 14:25
Distribution: Porteus and Nemesis
Location: USA

Re: Save.dat / changes confusion

Post#75 by Jack » 14 Aug 2016, 14:59

Also can you remember what the error message was that you got when you booted with changes=/dev/sdb2/Test/porteussave.dat?
When I boot up brokenman version it show that is going to use porteussave.dat and save when you shut down. And your don't show anything at all. There was no error it just booted up like it wasn't even there. I wish there was away to do a screen shot or a log file.
EDIT:
This is what mind looks like. And I try it both ways and both way does the same thing.

Code: Select all

    LABEL text
    MENU LABEL Text mode
    KERNEL vmlinuz
rem APPEND initrd-initrd.xz changes=/dev/sdb2/Test.porteussave.dat 3
    APPEND initrd=initrd.xz changes=/mnt/sdb2/Test/porteussave.dat 3
    TEXT HELP
        Run Porteus in text mode and
        start the command prompt only
    ENDTEXT
I'm doing this for you cause I will not use it. I just want to keep it in /mnt/sdb1/porteus/porteussave.dat.
EDIT:2
I can't run this if it don't load porteussave.dat.

Code: Select all

file  /mnt/sdb2/Test/porteussave.dat
ls  -lh  /mnt/sdb2/Test/porteussave.dat
ls  -sh  /mnt/sdb2/Test/porteussave.dat
du -h  /mnt/sdb2/Test/porteussave.dat
[[ ! -e f ]] && mkdir f;
mountpoint -q f && umount -f f;
sudo mount /mnt/sdb2/Test/porteussave.dat f;
du  -sh  f
df  -h  f
sudo umount f; rmdir f
I just like Slackware because I think it teach you about Linux to build packages where Ubuntu is like Windows you just install programs you want.

Post Reply