Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Sat 20 Oct 2018, 00:37
All times are UTC - 4
 Forum index » House Training » Users ( For the regulars )
Got my entire ext3 partition overwritten
Moderators: Flash, Ian, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [9 Posts]  
Author Message
nic007


Joined: 13 Nov 2011
Posts: 2655
Location: Cradle of Humankind

PostPosted: Fri 27 Jul 2018, 09:23    Post subject:  Got my entire ext3 partition overwritten  

I have a few frugal installs on an ext3 partition. So, I used an old script of mine to do some sfs editing. I created (or supposedly created) a folder called "puppyfilesystem" as the working directory. I must have forgotten to change the path of "puppyfilesystem" everywhere in the script because all data was wiped after running the script. Luckily had most things backed up to another partition. Shocked
Back to top
View user's profile Send private message 
Sailor Enceladus

Joined: 22 Feb 2016
Posts: 1546

PostPosted: Fri 27 Jul 2018, 15:45    Post subject:  

Note to self: Don't run any scripts by nic007 or your hard drive might get erased Surprised Smile Laughing
Back to top
View user's profile Send private message 
musher0

Joined: 04 Jan 2009
Posts: 12826
Location: Gatineau (Qc), Canada

PostPosted: Fri 27 Jul 2018, 17:05    Post subject:  

Sailor Enceladus wrote:
Note to self: Don't run any scripts by nic007 or your hard drive might get erased Surprised Smile Laughing

Bingo! Laughing

_________________
musher0
~~~~~~~~~~
Fidèle elle commença, ainsi elle restera. (Prov. canadien) /
Faithful she began, so will she stay. (Canadian prov.)
Back to top
View user's profile Send private message 
ITSMERSH


Joined: 02 May 2018
Posts: 359

PostPosted: Fri 27 Jul 2018, 18:07    Post subject:  

There's an old German saying: Schadenfreude ist die beste Freude (literally translated: malicious joy is the best joy (I'm sure there's an equal international saying for this)).

However: I don't agree with that saying / any of such sayings.

Good to have backups, though! Wink

Edit:

Btw. this wouldn't have happen by using the LazY Remaster Suite.

_________________
RSH
Back to top
View user's profile Send private message 
nic007


Joined: 13 Nov 2011
Posts: 2655
Location: Cradle of Humankind

PostPosted: Fri 27 Jul 2018, 21:22    Post subject:  

Old script I've been using for years to edit the loaded base sfs (not a remaster just a copy of /initrd/pup_ro2/*, manually editing a few things and then mksquashfs. I wanted to change the path of the working directory in the script to /mnt/sda3/puppyfilesystem but created the directory as /mnt/sda3 instead. Embarassed Mksquashfs was happy to "squash" the non-existing /mnt/sda3/puppyfilesystem by overwriting the data on /mnt/sda3. Mad Anyways - be careful!!!!
Back to top
View user's profile Send private message 
hamoudoudou

Joined: 24 Jul 2014
Posts: 1467
Location: rabat

PostPosted: Sun 29 Jul 2018, 07:06    Post subject: use editsfs, that is a well know Puppy tool.  

use editsfs, that is a well know Puppy tool.
But your error is human, whatever the codop used.. it's not programming error, it's yours., the man typing.
That people enjoy is not fair.. i will give you some scripts by Musher0 for automatization,.. if you need some laugh.
Back to top
View user's profile Send private message 
nic007


Joined: 13 Nov 2011
Posts: 2655
Location: Cradle of Humankind

PostPosted: Sun 29 Jul 2018, 08:13    Post subject:  

Yes, a human editing error. Nothing wrong with the script itself. Just thought I'd share it...of course some saw the opportunity to take a jibe at me. Smile This is the script I normally use for manual editing the base sfs, additional compression options added:
Code:
WrkDir="/puppyfilesystem"
rm -r $WrkDir
mkdir $WrkDir
cp -a /initrd/pup_ro2/* /puppyfilesystem
Xdialog -center -msgbox "/puppyfilesystem ready for edit.  Press OK when ready" 0 0
. /etc/DISTRO_SPECS
 PUPPYSFS="$DISTRO_PUPPYSFS"
Splash="rxvt -bg green -fg black -title "Progress" -geometry 80x6+360+360  -e mksquashfs $WrkDir /$PUPPYSFS"   
answer=`Xdialog --left --wrap --stdout --title "Compression Settings"  --combobox "Ready to compress to sfs file.
Higher compression levels produce smaller files but takes longer to compress.
Gzip compression produce bigger files than xz compression but compress faster. 
Older Puppys with pre-series-3 kernels must use gzip OLD compression.
Please select your choice from the menu, click 'OK' and .  This will take a while, please be patient." 0 80 "xz  DEFAULT" "xz  MEDIUM" "xz  HIGH" "xz  HIGHEST" "gzip  DEFAULT" "gzip  OLD" "NO COMPRESSION"`
case "$answer" in
        "xz  DEFAULT") $Splash -noappend -comp xz ;;
        "xz  MEDIUM") $Splash -noappend -comp xz -Xbcj x86 ;;
        "xz  HIGH") $Splash -noappend -comp xz -b 1048576 -Xdict-size 100% ;;
        "xz  HIGHEST") $Splash -noappend -comp xz -b 1048576 -Xbcj x86 ;;
        "gzip  DEFAULT") $Splash -noappend -comp gzip ;;
        "gzip  OLD") $Splash -noappend ;;
        "NO COMPRESSION") $Splash -noappend -noI -noD -noF -noX ;;
 esac
rm $WrkDir -r
Xdialog -center -title "SUCCESS!!!"  --no-buttons -infobox "Operation completed, exiting now" 0 0 3000
   
exit
Back to top
View user's profile Send private message 
foxpup


Joined: 29 Jul 2016
Posts: 571
Location: europa near northsea

PostPosted: Sun 29 Jul 2018, 11:34    Post subject:  

I want to wipe my ext3 partition. Is this the right tool to do it? Very Happy
Back to top
View user's profile Send private message 
nic007


Joined: 13 Nov 2011
Posts: 2655
Location: Cradle of Humankind

PostPosted: Sun 29 Jul 2018, 13:15    Post subject:  

foxpup wrote:
I want to wipe my ext3 partition. Is this the right tool to do it? Very Happy

Of course, be brave. Wink
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [9 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » House Training » Users ( For the regulars )
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0545s ][ Queries: 12 (0.0188s) ][ GZIP on ]