DebianDog - Jessie (21 June 2017)

A home for all kinds of Puppy related projects
Message
Author
User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#941 Post by fredx181 »

anikin wrote:Now I boot with <init=/bin/systemd> and mount-wizrd kind of works. It sees all 3 of my partitions. I mount sdc1 - OK. Go on to mount sdb1 - it mounts ... and freezes. Becomes stubborn as a mule https://www.youtube.com/watch?v=799trxDgoEc As I said, I don't use this modded version. I'm using the original one, that I hope will work OK for me under dash. I made 2 quick screenies tried to join them with peasyglue ... and failed. Oh, I see, peasyglue is not an important program - it's for jerks, like anikin Smile
Try the one attached (gtkdialog changed to gtkdialogbin inside)
And stop being a jerk!
I just meant it's a general problem for gtkdialog so it's not specially about we desperately need mount-wizard, nothing to do with you.

EDIT:
peasyglue requires libnetpbm10

Code: Select all

apt-get install libnetpbm10
then run it from terminal with switchsh:

Code: Select all

switchsh peasyglue
And it should work OK (does for me)

All these problems for programs using gtkdialog will be fixed in next ISO, (don't know how exactly yet but I'm sure it's possible thanks to the switchsh app)

Fred
Attachments
mount-wizard-orig.gz
mount-wizard-orig (fake .gz)
(1.96 KiB) Downloaded 133 times

anikin
Posts: 994
Joined: Thu 10 May 2012, 06:16

#942 Post by anikin »

And stop being a jerk!
Are you serious? I posted a comment with a smile on my face, you're posting back an insult. You mean, stop reporting problems?
Not that mount-wizard is a very important program (although can be nice when someone prefers a very basic desktop with no drive icons)...
I don't question your knowledge of bash scripting, but some of your comments are plain stupid. You can't tell people which programs are important, let them make their own decisions. Grow up Fred, stop being a little clown!

User avatar
rufwoof
Posts: 3690
Joined: Mon 24 Feb 2014, 17:47

#943 Post by rufwoof »

Thanks Fred. I dropped that cleaning code into a function and swapped out the .... working type indicator for a spinner whilst clearing man and docs. Reduced down my sfs from 1.1GB to 1.0GB.

Code: Select all

#!/bin/bash

function cleanup {
 echo "Cleaning..."
# rm -f tmpa/etc/X11/xorg.conf # if intend to port to another PC
 rm -f tmpa/var/lib/alsa/asound.state
 rm -f tmpa/root/.bash_history
 rm -f tmpa/root/.xsession-errors
 rm -rf tmpa/root/.cache
 rm -rf tmpa/root/.thumbnails
 rm -f tmpa/etc/blkid-cache
 rm -rf tmpa/etc/udev/rules.d/70-persistent*
 rm -f tmpa/var/lib/dhcp/dhclient.eth0.leases
 rm -f tmpa/var/lib/dhcpcd/*.lease
 rm -rf tmpa/etc/rc.d
 rm -rf tmpa/lib/consolefonts
 rm -rf tmpa/lib/keymaps
 rm -fr tmpa/var/lib/aptitude/*

 # Clean apt cache
 ls tmpa/var/lib/apt/lists | grep -v "lock" | grep -v "partial" | xargs -i rm tmpa/var/lib/apt/lists/{} ;
 ls tmpa/var/cache/apt/archives | grep -v "lock" | grep -v "partial" | xargs -i rm tmpa/var/cache/apt/archives/{} ;
 ls tmpa/var/cache/apt | grep -v "archives" | xargs -i rm tmpa/var/cache/apt/{} ;
 rm -f tmpa/var/log/* 2> /dev/null

 cd tmpa

 # zerosize (0 bytes) man and doc files...
zerosize() {

  spin='-\|/'
  i=0
  printf "[  "
  find $* | while read file; do
    # echo -n "."
    i=$(( (i+1) %4 ))
    printf "\r\r${spin:$i:1}]"
    rm -f $file
    touch $file
  done
  printf "\r\r\r"
}

 zerosize usr/share/doc -type f -size +1c
 zerosize usr/share/doc -type l
 zerosize usr/share/man -type f -size +1c
 zerosize usr/share/man -type l
 zerosize usr/share/info -type f -size +1c
 zerosize usr/share/info -type l
 zerosize usr/share/gnome/help -type f -size +1c
 zerosize usr/share/gnome/help -type l
 zerosize usr/share/gtk-doc -type f -size +1c
 zerosize usr/share/gtk-doc -type l

 chown -R man:root usr/share/man 

 cd ..
 sync
}

clear
echo This script assumes you have booted frugally
echo initrd and vmlinuz and filesystem.squashfs style
echo booted using something like grub4dos and are running
echo with all changes being recorded in memory
echo
echo It will take take all changes to date that have been
echo flushed to disk using SAVE and merge those changes
echo into the main filesystem squashfs file 
echo
echo At the end it will reboot the system
echo
echo The changes folder content will then be emptied
echo during the next reboot and the new filesystem
echo will be activated
echo

read -p "Are you sure you want to remaster a new main squashed filesystem? " -n 1 -r
echo    # move to newline
if [[ $REPLY =~ ^[Yy]$ ]]
then
 clear
 echo Remastering
else
 exit
fi

BOOT=`cat /proc/cmdline | grep EXIT`
if [ -z "${BOOT}" ]; then
 echo Remastering requires a static system.
 echo You need to have booted frugally session in order to remaster
 echo i.e. first choice in initial bootup menu
 sleep 5
 exit
fi

clear
read -p "Should the remaster include current session changes? " -n 1 -r
echo    # move to newline
if [[ $REPLY =~ ^[Yy]$ ]]
then
 /usr/bin/save2flash # Store latest changes
 sync
fi

BASE=`cat /proc/cmdline | awk 'BEGIN{FS="changes=EXIT:"} {print $2}' | awk 'BEGIN{FS=" "} {print $1}'`
if [ -z ${BASE} ]; then
 exit
fi

PART=`mount -l | grep changes-exit | awk 'BEGIN{FS=" "} {print $1}'`
MNT=`echo $PART | sed s/dev/mnt/`
mkdir -p $MNT 2> /dev/null
mount $PART $MNT 2> /dev/null

cd $MNT$BASE >/dev/null 2>&1
if [ ! -d changes ]; then # might have /mnt/sda1 or whatever already command line parameter 
 cd $BASE >/dev/null 2>&1 # such that cd $MNT$BASE fails
fi

mkdir remaster
cd remaster
mkdir -p tmp1 tmpa
# read filesystem.module to determine which of the two toggles to use
CURRENT=`cat ../filesystem.module | grep filesystem | grep squashfs`
mount -o loop ../$CURRENT tmp1/ >/dev/null 2>&1
mount -t aufs -o br:../changes:tmp1 none tmpa/
CURRENT=`echo $CURRENT | sed s/.squashfs//`
if [ ! -z `echo $CURRENT | grep 01` ]; then
 if [ -f ../filesystem.squashfs ]; then
   rm ../filesystem.squashfs
 fi
 cleanup
 mksquashfs tmpa ../filesystem.squashfs -comp lz4
 sed -i "s/filesystem01.squashfs/filesystem.squashfs/" ../filesystem.module
else
 if [ -f ../filesystem01.squashfs ]; then
   rm ../filesystem01.squashfs
 fi
 cleanup
 mksquashfs tmpa ../filesystem01.squashfs -comp lz4
 sed -i "s/filesystem.squashfs/filesystem01.squashfs/" ../filesystem.module
fi
sync
umount -f tmpa tmp1 >/dev/null 2>&1
rmdir tmpa tmp1
cd ..
rmdir remaster
umount $MNT >/dev/null 2>&1
cd changes
touch clear-changes-on-reboot # set up flag file so initrd1 will empty changes folder at next reboot
sync
echo The system needs to reboot - rebooting ...
wmreboot

User avatar
rufwoof
Posts: 3690
Joined: Mon 24 Feb 2014, 17:47

#944 Post by rufwoof »

anikin wrote:
And stop being a jerk!
Are you serious? I posted a comment with a smile on my face, you're posting back an insult. You mean, stop reporting problems?
Not that mount-wizard is a very important program (although can be nice when someone prefers a very basic desktop with no drive icons)...
I don't question your knowledge of bash scripting, but some of your comments are plain stupid. You can't tell people which programs are important, let them make their own decisions. Grow up Fred, stop being a little clown!
I clearly saw Fred's remark as being in jest anikin. A friendly tease, in no way intended as a actual insult. All friends around here mate :)

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

#945 Post by mcewanw »

Hi all,

I shouldn't be here - I'm on my extended break but happened to look into forum yesterday and saw wanderer's 'a modest proposal' and commented about wifi there. I also noted the new DD-Jessie... great... especially with attempted gtkdialog dash/bash fix-attempt. I thought you had the solution Fred... pity about mount-wizard. Could possibly use a specially compiled gtkdialog that uses system(bash -c command) rather than just system(command) in its actions.c code, but I'm not sure if that would fix all issues or just finding bash exported functions (and I haven't tried it). Alas, I'm interested in this issue for long time, so will no doubt keep following what you find despite my wanting to not use computer at all just now! :-)

@anikin and Fred: First Fred, you being from Holland clearly ran into a bit trouble trying to write humour in english! I understand you were just trying to be funny and in friendly humour with anikin by echoing his jerk comment. Unfortunately, it could (and was by anikin) interpreted differently as an insult.

I can see it wasn't intended as such, anikin - I'm not sure if your first language is english or not but please recognise Fred was 'trying' to be funny (but kind of failed on this attempt!). Please be tolerant and not take it too personally - you made the first joke attempt (which was also a bit ambiguous reading to me by the way) - best maybe not to joke in foreign language or always just accept it was joke. You are a useful asset to DD developments anikin so please relax.

William

EDIT: Main thing is we all have to avoid any kind of infighting when doing development work. Just accept occasional accidental or otherwise harsh comments and let's just get on with the technical work - that's the only important matter for developers. As it is, I find myself writing more about diplomacy now than about the technical issue! It's these infighting type issues that caused me to want a long (possibly forever) break in the first case - and I'm sure I'm not alone in how tiring I find such issues...
Last edited by mcewanw on Mon 26 Sep 2016, 05:39, edited 1 time in total.
github mcewanw

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

#946 Post by mcewanw »

Of course the 'best' solution would be for gtkdialog utility authors (including myself) to carefully write their scripts either to avoid bash or to start their scripts with #!/bin/bash and inside the gtkdialog <action> calls to functions to call the function via bash -c (so that bash exported functions will be found) - but, on its own, that would not be a good universal solution, since would force gtkdialog to always use bash underneath for function calling. May be other issues that would need addressed in such ways. It isn't a fault of gtkdialog itself, which uses the 'system' call and thus the underlying main shell when it makes calls itself.

I think I may already have modified weav (with bash -c in <action> function calls) to work okay even if dash is underlying (though I haven't checked that very carefully). I did towards the end try modifying wex in the same manner, but it being quite a complex program I didn't trust I wouldn't break it, so I left it requiring underlying sh -> bash shell for now. I intended making it dash compatible later, but if the relatively simple and neat switchsh solution (I checked out the C code for that) ends up working, that would be great since really too many gtkdialog scripts would otherwise need modified to work with underlying dash shell.

William
github mcewanw

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

#947 Post by mcewanw »

Maybe you need to have your 'gtkdialog script' (which goes to call gtkdialogbin via switchsh) check the first line of the main utility script: if it's #!/bin/bash then use switchsh, if it isn't than call up gtkdialog without switchsh.

A few utility scripts which have #!/bin/sh at the beginning incorrectly assume bash is the underlying shell, but that's really a script programming error, so they would still need their first lines modified to be #!/bin/bash to deal with the bashisms they actually contain.

William
github mcewanw

backi
Posts: 1922
Joined: Sun 27 Feb 2011, 22:00
Location: GERMANY

#948 Post by backi »

As rufwoof mentioned :

" Personally I found the different boot choices 1, 2 or 3 to be confusing at first, and settled on what seemed the more familiar (1 porteus style). 2 I've never used. 3 I have, but partition saving isn't as good IMO as savefolder save (boot 1)."

Do much agree.

I see it as an important idea.
Maybe a lot of newbies feel rejected to use this amazing Tool, by an overkill of boot options they don`t quite understand (like myself ).
This would make DD appear more easier and beginner friendly.
It is not so much a technical enhancement ,but more a psychological one .
The more complex methods could be given to a later point.

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#949 Post by fredx181 »

Hi anikin,
Oh, I see, peasyglue is not an important program - it's for jerks, like anikin Smile
Despite the smile I took your comment as sarcasm, so, my reply was not intended as a joke, but overreacted (I am a little allergic for the slightest tone of sarcasm and/or complaining).
You can't tell people which programs are important, let them make their own decisions.
Wasn't my intention to tell people which programs are important, but I agree it was a clumsy way of saying that mount-wizard is an exception, other programs like frisbee, pburn work well for me with the new gtkdialog setup.
(later found that peasyglue doesn't work also because it's calling gtkdialog3)

And... could you make mount-wizard-orig and peasyglue work ok now?

Let's be friends, (make love not war... :) )

Fred

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#950 Post by fredx181 »

Hi William, what are you doing here!

(="intended as funny this time" :) )
I thought you had the solution Fred... pity about mount-wizard.
Yes, sure it is, I should have tested more thoroughly, BTW.

I *think* the exception is in how gtkdialog is called in mount-wizard:
Line 202:

Code: Select all

eval $(_choose_action "$partitions" | gtkdialog -sc )
(through a pipe using eval)

I would love to make the 'gtkdialog script' (in /usr/bin) work also in such a case.
Maybe you have idea?
(but don't spend to much time on it, after all you're having a break)

In the end there's always a solution by modifying all (gtkdialog) scripts to be called via switchsh (and revert back to the 'normal' gtkdialog), but it's a lot of hassle.

Fred

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#951 Post by fredx181 »

Hi backi
As rufwoof mentioned :

" Personally I found the different boot choices 1, 2 or 3 to be confusing at first, and settled on what seemed the more familiar (1 porteus style). 2 I've never used. 3 I have, but partition saving isn't as good IMO as savefolder save (boot 1)."

Do much agree.

I see it as an important idea.
Maybe a lot of newbies feel rejected to use this amazing Tool, by an overkill of boot options they don`t quite understand (like myself ).
This would make DD appear more easier and beginner friendly.
It is not so much a technical enhancement ,but more a psychological one .
The more complex methods could be given to a later point.
So you are suggesting to have only one boot choice, porteus-boot ?

Don't know yet, then the whole idea of DebianDog being 'puppyfied' but still 'pure' Debian (Live) will be gone. (when live-boot-3 isn't one of the choices)

Fred

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

#952 Post by mcewanw »

fredx181 wrote: I would love to make the 'gtkdialog script' (in /usr/bin) work also in such a case.
Maybe you have idea?
(but don't spend to much time on it, after all you're having a break)

In the end there's always a solution by modifying all (gtkdialog) scripts to be called via switchsh (and revert back to the 'normal' gtkdialog), but it's a lot of hassle.

Fred
Yes, I'm determined to get back on the break... but temptation on this important issue was threatening me to abandon my peace... but back on break I go!

EDIT: Oh I forgot to say, I think you should leave the original gtkdialog app names as they are (since that's how they come) but instead have startup scripts (calling switchsh) with a consistent naming scheme we will all remember. Unless, that is, you do find a better way of simply calling gtkdialog up via switchsh when script is /bin/bash driven.

I understand the desire of backi and others to just present DebianDog with one boot code, and I would also go with porteus boot because of its usefulness. I think the idea would or should not be to abandon live boot 3, however, but simply present it later, via a link to a separate thread or post maybe, as an alternative mechanism, which is fully Debian compatible. There seems to be no doubt that the current three boot method presentation would be off-putting for many new users - it is pretty complicated to get ones head around all these boot concepts - so better indeed just to start new users off with porteus boot installation in detail.

William

Okay, over and out for now :-)
github mcewanw

User avatar
rufwoof
Posts: 3690
Joined: Mon 24 Feb 2014, 17:47

#953 Post by rufwoof »

mcewanw wrote:I understand the desire of backi and others to just present DebianDog with one boot code, and I would also go with porteus boot because of its usefulness. I think the idea would or should not be to abandon live boot 3, however, but simply present it later, via a link to a separate thread or post maybe, as an alternative mechanism, which is fully Debian compatible. There seems to be no doubt that the current three boot method presentation would be off-putting for many new users - it is pretty complicated to get ones head around all these boot concepts - so better indeed just to start new users off with porteus boot installation in detail.
Conceptually you install Debian, only use its repositories (stable) ... and can keep/run that forever - with apt-get update migrating you as required over time. Works pretty well in practice also. Jessie V1 as I call it (not the current 'beta') migrated from Wheezy into Jessie. A single Debian Dog, perhaps porteus boot style, using rox and jwm as the 'Official' DD would greatly simplify effort for developers/maintainers, but could retain the potential to be 'expanded' to use other choices (boot 3 style etc.) on more of a do at your own risk type basis (alleviating the pressure upon developers/maintainers).

Personally I've been using DD Jessie OpenBox with Thunar/pcmanfm and like that a lot, so jwm/rox wouldn't be my first choice, but as that's more in common with Puppy and if effort was more targeted towards that then I'd be happy to go along with/use that 'Official' DD.

As-is, its a potential can of worms ... too many variations IMO.

I'm off to dig out DD Jessie rox/jwm and frugally boot/apt-get update that to have a look.

backi
Posts: 1922
Joined: Sun 27 Feb 2011, 22:00
Location: GERMANY

#954 Post by backi »

Fredx181 wrote :
So you are suggesting to have only one boot choice, porteus-boot ?
Yes and no ...not really ....

But rufwoof and mcewanw made some good proposals for that kind of concept to think about.
Would be a good compromise . Why not ......just an idea !!
Rufwoof said :
" too many variations IMO"
That`s right ........this is what i feel too ......i am more and more loosing oversight over all this threads and cluttered topics .
More so for someone who is coming new to this project....is like facing a jungle of info .
Better to come back to one track.

User avatar
rufwoof
Posts: 3690
Joined: Mon 24 Feb 2014, 17:47

#955 Post by rufwoof »

Here's a version of the original jwm Debian Jessie (as per page 1 first posting), updated for all Debian updates to date. I've dropped in lz4 compressed squashed filesystem support, added support for /live/filesystem.module, added a remaster-filesystem script to the desktop (and save2flash). I've also reduced down prompts for save y/n at shutdown.

https://drive.google.com/file/d/0B4MbXu ... sp=sharing

Inteded solely to be used as a frugally booted pup. menu.lst example entry is included.

Download the sfs, copy the content of that to the / folder of a ext partition, edit your menu.lst to add a entry ... and boot.

Try out the remaster-filesystem desktop icon to see how quick it remasters :) Also note how quick it boots. Faster operation comes at the sacrifice of less compression so the pup is larger (the above sfs is around 228MB, but the filesystem.squashfs within that is around 260MB) compared to the 190MB or perhaps less if slower high compression had been used. There's also libreoffice + libreoffice-gnome (so can have libre as a tray quickstart) merged into a single sfs, along with firefox-esr. Those were created using DebianDog's Apt2SFS (sourced from Debian repository) and dropped into /live with entries in filesystem.module so that they're loaded at startup.

All changes are stored in memory and are only saved across reboots if you either run the save2flash desktop icon, or run the remaster-filesystem desktop icon.

To add other programs
apt-get update
to update the package database and then
apt-get install <program>
for example
apt-get install numlockx
to install numlock on
or perhaps dogradio
apt-get install dogradio
(dance groove USA is a nice 'chill out' background music channel)
...or open up Menu, Settings, Synaptic package manager for a GUI version.
Don't forget to save (save2flash desktop icons flushes memory recorded changes to disk (savefolder (/live/changes)), remaster shifts all of /live/changes into the main filesystem.squashfs.

(Very) far from polished. More of a template to perhaps evolve as a group project? ROX and menus need re-working. For example currently to launch firefox you have to Menu, Utility, Run and type in firefox-esr in order to launch firefox and I can't find any jwm config tools ...etc.
Last edited by rufwoof on Mon 26 Sep 2016, 18:03, edited 1 time in total.

backi
Posts: 1922
Joined: Sun 27 Feb 2011, 22:00
Location: GERMANY

#956 Post by backi »

Just put it to an Usb-Flash started a test run .
As you said far from polished
But works O.K .......
Would be a good introduction for D-D beginners ....simple to start ...not so overloaded with all these boot and save options and so on (these are better for more advanced users ) . .

User avatar
rufwoof
Posts: 3690
Joined: Mon 24 Feb 2014, 17:47

#957 Post by rufwoof »

backi wrote:Just put it to an Usb-Flash started a test run .
As you said far from polished
But works O.K .......
Would be a good introduction for D-D beginners ....simple to start ...not so overloaded with all these boot and save options and so on (these are better for more advanced users ) . .
I've just been using DebianDog Apt2SFS for the first time for me. Fantastic. So far applied it to libreoffice (plus libreoffice-gnome so it works as a quick launcher in the tray) and firefox-esr. Add them to /live and put entries for them into filesystem.module, reboot and voila. Keeps the main filesystem lean, sourced from Debian repository ... all working great.

As-is DD jwm/rox version is untidy and needs a thorough clean up to getting it to work in a more 'usual' manner. But the foundation is there already.

I've just uploaded another version (earlier posting updated to reflect that), in which I've added gtk2 config files that makes the fonts look tidier. Plus libre and firefox-esr sfs (I merged libreoffice and libreoffice-gnome into a single sfs).

backi
Posts: 1922
Joined: Sun 27 Feb 2011, 22:00
Location: GERMANY

#958 Post by backi »

Hi ruf!
I've just been using DebianDog Apt2SFS for the first time for me. Fantastic.
I thought you did know it .
Apt2SFS is a "Killer tool ".
This is one and many otherclever and useful tools and gadgets like pet2deb or pet2sfs and so on , makes D-D and Mintpup so outstanding .It keeps it near to Puppy .

Using sfs or squashfs apps (just loading them on demand ) to keep the " Coresystem " clean and lean instead of installing them is my favorite method .
D-D is a cool fusion between Puppy and Debian .

User avatar
rufwoof
Posts: 3690
Joined: Mon 24 Feb 2014, 17:47

#959 Post by rufwoof »

Oooo! Not as incomplete as I thought. Just uses a different setup for jwm than what I was familar with (puppy).

For instance you edit ~/.jwm/jwm.tail to perhaps change the tray clock format or number of virtual desktops and then run menu-puppy and then jwm -restart. That also populates the icons/programs that I thought weren't being loaded (Libre sfs programs, firefox-esr ...etc).

There's a whole army of scripts/programs in /opt/bin ... just don't know myself what most of those are for/do.

User avatar
rufwoof
Posts: 3690
Joined: Mon 24 Feb 2014, 17:47

#960 Post by rufwoof »

I believe DebianDog has a max count of 7 sfs's that can be loaded.

Looking at linuxrc in intrd around line 380

Code: Select all

## Finish:
# Create 7 free loop devices for truecrypt, etc...
x=`losetup | tail -n1 | cut -d: -f1 | sed 's@/dev/loop@@'`; let y=x+7
while [ $x -le $y ]; do [ -b /dev/loop$y ] && break || mknod /dev/loop$y b 7 $y; let y=y-1; done
... wondering if increasing that would be sufficient to expand that number ... perhaps to 128 ???

... seems to. Set y=255, set filesystem.module to load 13 sfs's at bootup and they all loaded ok.

Post Reply