I hadn't realized that Fatdog writes to a sparse file

For talk and support relating specifically to Puppy derivatives
Message
Author
PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

I hadn't realized that Fatdog writes to a sparse file

#1 Post by PappyPuppy »

when I go to back up my .ext4 savefile in Fatdog, it errors out of the copy with an lseek error. I assume this is due to some sort of offline 0 count for the empty part of the file. Is there a copy command that can handle this? I just want a simple backup procedure for my savefile.

I might have missed something in the helpfiles for Fatdog so I'll take a look in their help guide.

At least the savefile boots are working now.

If it's too messy a question to answer quickly, just saying that is enough - I'm sure I would eventually stumble across an article out their on the Internet.

PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

I now realize it's the USB flash stick

#2 Post by PappyPuppy »

I now realize that the 128 GB stick I have only shows up as 4GB. Perhaps I had formatted it on Windows. I might just take a new stick and only use it for Fatdog. That might work.

User avatar
Burn_IT
Posts: 3650
Joined: Sat 12 Aug 2006, 19:25
Location: Tamworth UK

#3 Post by Burn_IT »

And why should formatting it on Windows have been a problem that will cause it to only show 4Gb??

If it was going to be limited it would have to be Fat16 and that is not a Windows problem alone. It would be 2Gb not 4Gb
"Just think of it as leaving early to avoid the rush" - T Pratchett

User avatar
drunkjedi
Posts: 882
Joined: Mon 25 May 2015, 02:50

#4 Post by drunkjedi »

If the drive is new check it with F3 software, search on this forum.
Or in Windows with h2testw.

I have got fake usb drives, but I got the money back.
Last edited by drunkjedi on Fri 16 Dec 2016, 17:02, edited 1 time in total.

PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

I rechecked my two flash sticks

#5 Post by PappyPuppy »

I am trying to copy again.

PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

The cp referred to above DID fail again

#6 Post by PappyPuppy »

cp: error writing '.../thesavefile.ext4 ...' : File too large
cp: failed to extend '.../thesavefile.ext4' : File too large
Failed to copy '.../thesavefile.ext4'

It copies up to about 3.7GB, then gives the above error.

User avatar
drunkjedi
Posts: 882
Joined: Mon 25 May 2015, 02:50

#7 Post by drunkjedi »

What filesystem is on that drive?

Fat32, ntfs?

Fat32 can't have a single file of 4Gb.

User avatar
Burn_IT
Posts: 3650
Joined: Sat 12 Aug 2006, 19:25
Location: Tamworth UK

#8 Post by Burn_IT »

Is Puppy running under a Fat32 file system.
A Frugal Puppy running under FAT32 will try to create a virtual container for the Puppy file system, which may be EXT4 , but ithe containing file will be limited by the FAT32 File system limit of 4Gb per file.
"Just think of it as leaving early to avoid the rush" - T Pratchett

PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

NTFS

#9 Post by PappyPuppy »

The drive I am copying from is NTFS.

If I right click on the drives though, it says it's only 4GB. Actually, the drive I'm copying from is almost 1 Terabyte and it's filled up to about 131 GB. It seems like just a failure of the cp command itself. I might have to look at the source code. Neither the NTFS drive nor the Flashstick would mind having a huge file on them. It's a command issue. And when I rightclick on the drive, it SHOULD report the correct size. But it says extended attributes not supported. Not sure what that means.

User avatar
drunkjedi
Posts: 882
Joined: Mon 25 May 2015, 02:50

#10 Post by drunkjedi »

Not the drive from where you are copying from.
But the usb sticks that you are copying into...
Are they Fat32?

PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

Fat32

#11 Post by PappyPuppy »

The USB stick is Fat32 - perhaps I need to format it NTFS? I now remember - I had wanted to try a new flash stick for that reason. I guess I can either reformat or buy another flash stick and start over since I have enough excuse. I'll pick up another.

I just took a look at what's on the disk - I can just find some way to reformat it and start over. Then recopy the info that's lost. I guess I could do a reformat that preserves the data, but I'm not too worried.

GParted maybe?

PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

Gparted hangs up on the unmount

#12 Post by PappyPuppy »

Some problem.

PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

Now I understand Gparted's unmount command

#13 Post by PappyPuppy »

I killed gpartedbin/gparted and started over.

I chose unmount this time and waited a longer time, it finally unmounted and allowed the Gui menu item to reformat to be enabled.

So I chose NTFS and it does it in like 10 seconds.

Then I recopied the savefile and it copied fine.

So that works. Now I can reback up the stuff erased.

One major concern though: When I look at the properties of the USB stick, it says it's 121GB, but with 117GB free. If it's really written a 16GB file, it should be about 105GB free. So I don't know.

But when I look at the properties of the file on it's folder, it says that it's 16GB this time (unlike before when it said 4GB). So perhaps sparseness allows the file table to take up less room? I don't know.

User avatar
drunkjedi
Posts: 882
Joined: Mon 25 May 2015, 02:50

Re: Now I understand Gparted's unmount command

#14 Post by drunkjedi »

PappyPuppy wrote:One major concern though: When I look at the properties of the USB stick, it says it's 121GB, but with 117GB free. If it's really written a 16GB file, it should be about 105GB free. So I don't know.

But when I look at the properties of the file on it's folder, it says that it's 16GB this time (unlike before when it said 4GB). So perhaps sparseness allows the file table to take up less room? I don't know.
Yes that's how a sparse file should behave.
Sparse file would take less space on disk when looked at whole disk, while it will show it's intended size when looking up the file alone.
The size taken up on disk will increase/decrease with use/edits.

This helps in efficient use of disk space.

See https://en.m.wikipedia.org/wiki/Sparse_file

The 'extended attributes not supported' error you got maybe was because of Fat32 not supporting Sparse files.

PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

Now I have a new problem

#15 Post by PappyPuppy »

Now the OS no longer recognizes my flash stick. I was copying a directory when I got an input-output error and everything just died. I can't even get the operating system to recognize it. I just tried to take a step forwards by backing up stuff, and it's all gone. Something about Libparted bug.

Flash sticks DO die I hear, I'll have to buy a new one. This is taking too much time.

PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

I told Gparted to ignore the bug

#16 Post by PappyPuppy »

I will try to reinitialize the stick , repartitio, etc..

PappyPuppy
Posts: 409
Joined: Sat 01 Oct 2016, 00:27

Gparted GUI application

#17 Post by PappyPuppy »

Lost the command Gparted - it needs to be reinstalled. Why?

User avatar
drunkjedi
Posts: 882
Joined: Mon 25 May 2015, 02:50

#18 Post by drunkjedi »

Start fatdog fresh without savefile, with savefile=none boot option.

And see...

User avatar
Burn_IT
Posts: 3650
Joined: Sat 12 Aug 2006, 19:25
Location: Tamworth UK

#19 Post by Burn_IT »

I wonder if you could get this sort of error if yoou happened to get one of those USB sticks that pretend to be bigger than they really are??
"Just think of it as leaving early to avoid the rush" - T Pratchett

User avatar
drunkjedi
Posts: 882
Joined: Mon 25 May 2015, 02:50

#20 Post by drunkjedi »

Burn_IT wrote:I wonder if you could get this sort of error if you happened to get one of those USB sticks that pretend to be bigger than they really are??
But I think he tested that.
I suggested to test it earlier.
drunkjedi wrote:If the drive is new check it with F3 software, search on this forum.
Or in Windows with h2testw.

I have got fake usb drives, but I got the money back.
He answered he rechecked and found OK.
Maybe didn't use the tools I suggested.
Last edited by drunkjedi on Fri 16 Dec 2016, 17:02, edited 1 time in total.

Post Reply