Warning: this is an htmlized version!
The original is across this link,
and the conversion rules are here.
#######
#
# E-scripts on installing Debian on partitions, small partitions,
# floppies, etc.
#
# Note 1: use the eev command (defined in eev.el) and the
# ee alias (in my .zshrc) to execute parts of this file.
# Executing this file as a whole makes no sense.
#
# Note 2: be VERY careful and make sure you understand what
# you're doing.
#
# Note 3: If you use a shell other than zsh things like |&
# and the for loops may not work.
#
# Note 4: I always run as root.
#
# Note 5: some parts are too old and don't work anymore. Some
# never worked.
#
# Note 6: the definitions for the find-xxxfile commands are on my
# .emacs.
#
# Note 7: if you see a strange command check my .zshrc -- it may
# be defined there as a function or an alias.
#
# Note 8: the sections without dates are always older than the
# sections with dates.
#
# This file is at <http://angg.twu.net/e/debian0.e>
#           or at <http://angg.twu.net/e/debian0.e.html>.
#        See also <http://angg.twu.net/emacs.html>,
#                 <http://angg.twu.net/.emacs[.html]>,
#                 <http://angg.twu.net/.zshrc[.html]>,
#                 <http://angg.twu.net/escripts.html>,
#             and <http://angg.twu.net/>.
#
#######



#######
#
# mini rootdir at /root
#
#######

mkdir /root/bin/
mkdir -p /root/ZHTML/escripts/
cp -v /home/root/ZHTML/escripts/*.e /root/ZHTML/escripts/
cp -v /home/root/.zshrc /root/.zshrc
cp -v /home/root/.emacs /root/.emacs

# (find-fline "/etc/passwd")
# rroot::0:0:root:/root:/usr/bin/zsh




#######
#
# Running dinstall from a chrooted directory
#
#######

insmod $MODULES/loop.o

umount /rootdisk/proc

rm -Rv /rootdisk
mkdir /rootdisk
cd /rootdisk/
tar -xvzf /root/rootdisk.tgz

umount -a
mount -t proc proc2 /rootdisk/proc
mount

chroot /rootdisk /sbin/dinstall

# From: /dev/hdd3 /deb20
# Use "killall dinstall" to make things go on
reset
myreset
rc.local
logout




#######
#
# mounting on b1 (jun99)
#
#######

# (find-fline "/etc/fstab")
# (find-fline "/etc/init.d/")
# (find-fline "/etc/init.d/mountall.sh")

mkdir /b1/{big,c5}

# Remount /big and /c5 on /b1/big and /b1/c5:
#
umount /big
umount /c5
mount /b1/big
mount /b1/c5
rmdir /big /c5
[[ -e /big ]] || { ln -s b1/big /big && echo big on /b1/big }
[[ -e /c5  ]] || { ln -s b1/c5  /c5  && echo c5  on /b1/c5  }
laf -d /big
laf -d /c5
mount

# Remount big and c5 on /:
#
umount /b1/big
umount /b1/c5
rm -fv /big /c5
mkdir /big /c5
mount /big
mount /c5
laf -d /big
laf -d /c5
mount




#####
#
# boot-floppies-2.2.13 source 
# 2000jul12
#
#####

# «boot-floppies-src»
pdsc $SDEBIAN/dists/potato/main/source/admin/boot-floppies_2.2.13.dsc
cd /usr/src/boot-floppies-2.2.13/




#######
#
# boot-floppies source (slink)
#
#######

# slink src1
cd /cdrom/
cp -dipPv dists/slink/main/source/admin/boot-floppies_2.1.8.dsc \
	  dists/slink/main/source/admin/boot-floppies_2.1.8.tar.gz /debian

pdsc /debian/dists/slink/main/source/admin/boot-floppies_2.1.8.dsc
cd /usr/src/boot-floppies-2.1.8/
find * -type f | grep -v CVS > .files
glimpseindex -H . -F < .files

cd /usr/src/boot-floppies-2.1.8/
debian/rules binary	|& tee odrb

# (find-bfsrcfile "odrb")
# (find-bfsrcfile "debian/rules")

# (find-bfsrcfile "")
# (find-bfsrcfile "README")
# (find-bfsrcfile "scripts/rootdisk/")
# (find-bfsrcfile "scripts/basedisks/")

# (find-bfsrcfile "utilities/dinstall/")
# (find-bfsrcfile "utilities/dinstall/extract_kernel.c")

# (find-bfsrcfile "utilities/dinstall/dinstall.h" "KERDISKIMG")
# (find-bfsrcfile "utilities/dinstall/main.c" "KERDISKIMG")
# (find-bfsrcfile "utilities/dinstall/choose_medium.c" "kernel_image_filename")
# (find-bfsrcfile "utilities/dinstall/choose_medium.c" 244)


rm -Rv	/usr/src/boot-floppies-1.2.23
cd	/usr/src/
dpkg-source -x $DEBIAN/bo/source/admin/boot-floppies_1.2.23.dsc
cd	/usr/src/boot-floppies-1.2.23

cd /big/deb13/bo/disks-i386/1997-05-30
cd /usr/src/boot-floppies-1.2.23
# (find-bffile "Makefile" "drv1440.bin:")
# (find-bffile "basedisks.sh" "floppy_split")
# (find-bffile "basedisks.sh" "unpack")
# (find-bffile "basedisks.sh" "Los_Angeles")
# (find-bffile "utilities/floppy_split.c")

# (find-fline "foo.sh")
# (find-bffile "scripts/rootdisk/prototype/etc/rc" "fstab")
# (find-bffile "scripts/rootdisk/prototype/sbin/dinstall" "fstab")




######
#
# cflow (slink)
#
######

# (find-fline "/usr/doc/cflow/")
# (find-vldifile "cflow.list")

cd /usr/src/boot-floppies-2.1.8/utilities/dinstall/
make -n |& tee ~/o
# (find-fline "~/o")

cd /usr/src/boot-floppies-2.1.8/utilities/dinstall/
cflow -D_GNU_SOURCE -DARCH=i386 -DARCHNAME='"i386"' -DKVER='"2.0.35"'	\
      -DLINGUA='"C"' -DINCLINGUA='"messages/lang_C.h"'			\
   *.c > ~/o
agrep -v '\{\}' < ~/o > ~/o2

# (find-fline "~/o")
# (find-fline "~/o2")





#######
#
# Writing a boot floppy on a bad disk
#
#######

# (find-es "floppy" "superformat")

# (find-diskscfile "")
# (find-diskscfile "install.bat")

mountloop0L $SLINKB1/dists/slink/main/disks-i386/current/drv1440.bin

umount /A
# mkdosfs -c /dev/fd0

mountloop0L $SLINKB1/dists/slink/main/disks-i386/current/resc1440.bin
cd /L
mcopy * a:
syslinux /dev/fd0

mount /dev/fd0 /A
diff -qrs /A /L

# Not working very well...





#######
#
# b1
#
#######

# mount | perl -nle 'm:/dev/(.*) on / type: && print $1;'

cd /
mkdir /b6
mount /dev/hdc6 /b6
mkdir /b1
mount /dev/hdc1 /b1
mkdir /big
mount /dev/hdd3 /big -o ro
[ -e debian ] || ln -s /b6/debian debian
[ -e snarf  ] || ln -s /c5/snarf  snarf
[ -e home   ] || ln -s /b6/home   home
[ -e /usr/0src ] || { mv /usr/src /usr/0src; ln -s /b6/6usrc /usr/src }


# Last update: 98nov21

cd ~/HASH/
dpkg -iE --ignore-depends=emacs /debian/bo/binary-all/web/w3-el_2.2.26-1.deb
dpkg -iE gnuserv
dpkg -iE elisp-manual
 
dpkg -iE /debian/non-free/binary-i386/utils/glimpse_4.1-1.deb
dpkg -iE /debian/local/icont_9.3-1_i386.deb /debian/local/iconx_9.3-1_i386.deb

# dpkg -iE xfnt75 xbase xfntbase xserver-svga
dpkg -iE xfnt75 xbase xfntbase /snarf/ftp/ftp.debian.org/debian/dists/proposed-updates/xserver-svga_3.3.2.3-2_i386.deb
dpkg -iE xpm4g fvwm-common fvwm
dpkg -iE libpng0g /debian/non-free/binary-i386/text/gs-aladdin_5.10-9.deb
dpkg -iE gv

dpkg -iE dpkg-perl ed
dpkg -iE tetex-base tetex-bin
dpkg -iE tetex-doc
dpkg -iE tetex-extra

# Output of initex is in /tmp/tex01202aaa
# If you want to change the default settings,
# use /usr/bin/texconfig to configure teTeX.

dpkg -iE liblockdev0g dip fetchmail
dpkg -iE tcpdump libpcap0
dpkg -iE xlib6g-dev tcl8.0 tcl8.0-dev tk8.0 tk8.0-dev expect5.24 expect5.24-dev

# dpkg -i xfnt75 xbase xfntbase xserver-s3
# dpkg -i xpm4g fvwm-common fvwm

# dpkg -iE luxman shhmsg shhopt snake4 xlaby xtron xsok purity
# dpkg -r luxman shhmsg shhopt snake4 xlaby xtron xsok purity

dpkg -iE /debian/non-free/binary-i386/utils/unarj_2.41a-6.deb	\
	/debian/non-free/binary-i386/utils/unzip_5.32-1.deb	\
	/debian/non-free/binary-i386/utils/zip_2.20-2.deb

[ -e /dev/cdrom ] || ln -s mcd /dev/cdrom
[ -e /bin/zsh   ] || ln -s /usr/bin/zsh /bin/zsh
dpkg -iE workbone
dpkg -iE dosfstools mtools

# Netscape:
dpkg -iE libc5 libg++27 motifnls xlib6 xpm4.7
ln -s /snarf/ftp/ftp12.netscape.com/pub/communicator/4.07/shipping/english\
/unix/linux20/professional_edition\
/communicator-v407-export.x86-unknown-linux2.0_libc5.tar.gz /tmp/
# dpkg -i /debian/contrib/binary-i386/web/netscape4_4.0-12.deb
dpkg -i ~/SLINKB2/netscape4
rm /tmp/communicator-v407-export.x86-unknown-linux2.0_libc5.tar.gz

# Oops, eu agora preciso de uma versão glibc!



dpkg -iE doc-debian doc-linux doc-linux-text








######
#
# Some standard configurations and links
#
######

[ -e /bin/zsh ] || ln -s /usr/bin/zsh /bin/zsh
ln -s /usr/bin/perl /usr/local/bin/perl
# (find-fline "/etc/passwd")
# (find-fline "/etc/inittab" "tty6\n")
# (find-fline "/etc/fstab")
# (find-fline "/etc/ppp/options" "auth\n")




######
#
# Netscape plugins
#
######

gzip -cd /snarf/http/www.geocities.com/TimesSquare/Labyrinth/5084/flash/npflash.so.gz > ~/.netscape/plugins/npflash.so

rm -Rv ~/tclplug20-x86-linux2/
cd
tar -xvzf /snarf/ftp/ftp.scriptics.com/pub/tcl/plugin/tclplug20-x86-linux2.tar.gz
cd ~/tclplug20-x86-linux2/




#######
#
# StarOffice
#
#######

rm -Rv /usr/src/so50/
cd /usr/src/
tar -xvf /snarf/ftp/world-domination.mit.edu/pub/StarOffice/unxlnxi/so50_01.tar

# (find-fline "/snarf/http/www.stardivision.com/")
# (find-fline "/snarf/http/www.stardivision.com/office/so5_licenses_body.html")
# (find-fline "/snarf/http/www.stardivision.com/office/so5_licenses_body.html")
# (find-fline "/snarf/http/www.stardivision.com/office/so5linux_body.html")
# (find-fline "/snarf/http/support.us.stardivision.com/Registration/Download.asp?*Operation+System=09&Operation+System=09&*Language=01:49")

# (write-heredoc "~/o")

# Eduardo Ochs edrx@mat.puc-rio.br
# GNJ79WWGK7KUTZLIP63HVI
cd /usr/src/so50/office50_inst/
# setup

# Your registration key is GNJU9WW7E2KJAQBIP63B2TOFZECJ
# Your customer number is 1008622

# (find-fline "/usr/src/so50/")




#######
#
# diff'ing home dirs
#
#######

diff -qrs /b1/0home /home > ~/o
# perl -nle '/Files (.*) and (.*) are identical/ && print $1' < ~/o
  perl -nle '/Files (.*) and (.*) are identical/ && unlink $1' < ~/o

diff -qrs /home/root /big/home981121/root |& tee ~/o
perl -nle 'm/Files (.*) and (.*) are identical/ && print $1' < ~/o |& tee ~/o2
perl -nle 'm/Files (.*) and (.*) are identical/ && print $2' < ~/o |& tee ~/o3

# (find-fline "~/o2")





#######
#
# Samba
#
#######

# (find-fline "/debian/debian/main/binary-i386/Packages-all")
# (find-fline "/debian/debian/main/binary-i386/Packages-all" "Package: samba")
# (find-fline "~/ICON/detrans2.icn")

# (find-fline "~/CB/bin-ls-lR.i")


alias smbclizabel='smbclient \\\\Izabel\\cd-izabel tv -U edrx'

function dl-izabel () {
  cd /debian/
  ~/ICON/detrans2 $* |& tee ~/toget
  smbclient '\\Izabel\cd-izabel' tv -U edrx < ~/toget
}

dl-izabel libwww-perl
dl-izabel libmime-base64-perl

# (w3-open-local "/usr/doc/lg/issue19/micro.html")
# (w3-open-local "/usr/doc/lg/issue24/nelson.html")
# (find-fline "/usr/doc/samba/")
# (find-fline "/usr/doc/samba/faq/Samba-meta-FAQ.txt.gz")
# (find-fline "/usr/doc/samba/faq/sambafaq.txt.gz")
# (find-fline "/usr/doc/samba/examples/")
# (find-fline "/usr/doc/samba/examples/simple/")
# (find-fline "/usr/doc/samba/examples/printing/smbprint" 77)
# (find-fline "/usr/doc/smbfs/")

echo quit | smbclient '\\Izabel\cd-izabel' tv -d A -U edrx |& tee ~/osc
# (find-fline "~/osc")

smbmount //Izabel/cd-izabel /cdrom \
  -I 10.0.1.13 -U edrx -P tv
# (find-fline "/proxy/usr/src/linux/")
# (find-fline "/proxy/usr/src/linux/")
# (find-fline "/proxy/home/var/src/linux/fs/smbfs/")
# (find-fline "/proxy/home/var/src/linux/fs/smbfs/sock.c" "server->data_ready == NULL\\n")

dpkg -L samba

mkdir /samba
mount 

/usr/doc/samba/faq/sambafaq.txt.gz
# (w3-open-local "/usr/doc/samba/faq/sambafaq.html")





dpkg -i lg-base lg-issue19 lg-issue24 xserver-s3



xfnt75
xbase
xfntbase
xserver-svga
xpm4g
fvwm-common
fvwm


# (find-fline "~/README.mirrors")

# (find-fline "~/PERL/promit")

# (find-fline "~/CB/bin-ls-lR.i")
cd /debian/
~/ICON/detrans2 $(<<'---'
xfnt75
xbase
xfntbase
xserver-svga
xpm4g
fvwm-common
fvwm
---) |& tee ~/toget
smbclient '\\Izabel\cd-izabel' -U edrx < ~/toget


wget http://linux.if.usp.br/ftpmaster/.1/ftp.debian.org/debian/hamm/hamm/binary-i386/net/samba_1.9.18p8-2.deb


(find-fline "~/ZHTML/linux.ht" "-- debmi")
(find-w3node "Top")
(w3-open-local "http://www.debian.org/misc/README.mirrors")
(w3-fetch "http://www.debian.org/misc/README.mirrors")

(find-fline "~/README.mirrors")
(find-fline "/linux.if.usp.br:/debian/")

(w3-fetch "http://linux.if.usp.br/


/ftpmaster/.1/ftp.debian.org/debian/hamm/hamm/binary-all/x11/xfnt75_3.3.2.3-1.deb


cd /debian/
~/ICON/detrans2 $(<<'---'
debian/main/disks-i386/2.0.10_1998-07-21/base14-1.bin
debian/main/disks-i386/2.0.10_1998-07-21/base14-2.bin
debian/main/disks-i386/2.0.10_1998-07-21/base14-3.bin
debian/main/disks-i386/2.0.10_1998-07-21/base14-4.bin
debian/main/disks-i386/2.0.10_1998-07-21/base14-5.bin
---) |& tee ~/toget
smbclient '\\Izabel\cd-izabel' -U edrx < ~/toget







#######
#
# /etc
#
#######

# (find-zshnode "Conditional Expressions")
# (find-zshnode "Complex Commands")

function conffile () {
  [ -e $1.orig ] || mv -iv $1 $1.orig
  if [ -n ''$2 ]; then
    cp -v $2 $1
  else
    cat > $1
  fi
  echo
}

# Net configuration
#
# "auth" -> "#auth":
# (find-fline "/etc/ppp/options" "auth\n")
#
conffile /etc/networks <<'---'
loopback 127.0.0.0
localnet 0.0.0.0
---
conffile /etc/hosts <<'---'
127.0.0.1          localhost
0.0.0.0            angg angg.nowhere
---
conffile /etc/resolv.conf <<'---'
search .
nameserver 200.240.18.1
---
cd /etc/init.d/
/etc/init.d/netstd_init	stop
/etc/init.d/netbase	stop
/etc/init.d/netbase	start
/etc/init.d/netstd_init	start
/etc/init.d/apache	restart

echo 'tty1\ntty2\ntty3\ntty4\ntty5\ntty6\ntty7\ntty8\ntty9\ntty10\ntty11\ntty12' | conffile /etc/securetty

# (find-fline "/etc/init.d/")
# (find-fline "/etc/rc2.d/")
# lynx http://127.0.0.1/
# (find-fline "/usr/doc/HOWTO/NET-3-HOWTO.gz" "/etc/networks")


# inittab stuff
#
conffile /etc/securetty <<'---'
# /etc/securetty: list of terminals on which root is allowed to login.
# See securetty(5) and login(1).


---
conffile /etc/inittab /home/replace/etc/inittab.deb
telinit q





#######
#
# inittab tricks
#
#######

kbrequest:
  man inittab
  
(find-fline "/usr/doc/kbd/")
(find-fline "/usr/share/keytables/")
(find-fline "~/replace/defkeymap850b.map")
	alt	keycode 103 = Spawn_Console


(find-fline "~/replace/etc/inittab.deb")

# (find-esfile "hardware.e" "svgatextmode")
# (find-repletcfile "TextConfig")
kb::kbrequest:/sbin/stm



cp -b -V existing ~/replace/etc/inittab.deb /etc/inittab
telinit q



(find-fline "~/replace/etc/securetty")





#######
#
# some dpkg options
#
#######

dpkg --help
dpkg --force-help
dpkg -Dhelp
dpkg-deb --help

# (find-fline "~/dhelp")
l ~/dhelp



#######
#
# dpkg source
#
#######

# (find-fline "$BO/Packages" "sgml")
cd $BOSH
dpkg -i debiandoc-sgml sp sgmlspm

rm -Rv /usr/src/dpkg-1.4.0.24/
cd     /usr/src/
dpkg-source -x $DEBIAN/dists/slink/main/source/base/dpkg_1.4.0.24.dsc
cd     /usr/src/dpkg-1.4.0.24/

dpkg-buildpackage |& tee odb

find * -name '*.[ch]' -or -name '*.cc' > .files.ch
etags -i $(<.files.ch)
glimpseindex -H . -F < .files.ch


# (find-dpkgtag "rundpkgauto")
# (find-dpkgfile "dselect/dselect.h" "urqresult falliblesubprocess")
# (find-dpkgfile "dselect/method.cc" "urqresult falliblesubprocess")



(defun find-libcf (&optional str)
  (interactive "slibc function name: ")
  (find-node "(libc)Function Index" str))

(defun find-libcf (&optional str)
  (interactive
   (format "slibc function name (default %s): "
	   (setq default (around-point-with-cset "0-9A-Za-z_"))))
  (find-node "(libc)Function Index" str))

(find-node "(libc)Function Index" "memset")

(debug-on-entry 'find-libcf)
(global-set-key [f9] 'find-libcf)

(setq debug-on-error t)
       (debug-on-entry 'find-etag)
(cancel-debug-on-entry 'find-etag)
       (debug-on-entry 'visit-tags-table)
(cancel-debug-on-entry 'visit-tags-table)
       (debug-on-entry 'tags-table-including)
(cancel-debug-on-entry 'tags-table-including)

(find-etag "find-tag")
(find-etag "find-tag-tag")
(find-etag "find-tag-interactive")
(find-etag "tags-table-including")

       (debug-on-entry 'find-tag-interactive)
(cancel-debug-on-entry 'find-tag-interactive)

# (code-c-d "dpkg" "/usr/src/dpkg-1.4.0.24/")
# (find-dpkgfile "dselect")





#######
#
# Samba
#
#######

dpkg -i libpwdb0 libpam-util libpam0 samba
dpkg --purge libpwdb0 libpam-util libpam0 samba
dpkg --purge samba

Something wrong with the package order...




#  Local Variables:
#  coding:               no-conversion
#  ee-delimiter-hash:    "\n#*\n"
#  ee-delimiter-percent: "\n%*\n"
#  ee-anchor-format:     "«%s»"
#  ee-charset-indicator: "Ñ"
#  End: