experchange > slackware

notbob (01-05-20, 09:10 PM)
OK. I'm ready to try.

I've got an W10 box, but I wanna get back to Slackware, yet keep the
W10 stuff fer the "media" stuff it can do, so well.

It's an HP Slimeline Desktop PC 270-p0xx box with a i3-7100 gen 7 box
(64 bit) with 8G RAM and a SATA 1T HDD (Toshiba DT01ACA100) HDD (?).
I'll use a stock 14.2 d/l --full install-- to put on it. Will it
work?

If so, HOW? ;)

nb
notbob (01-05-20, 09:16 PM)
On 2020-01-05, notbob <notbob> wrote:

Er...."dual-boot". ;)
[..]
Grant Taylor (01-06-20, 02:04 AM)
On 1/5/20 12:10 PM, notbob wrote:
> Will it work?


I would expect that you can.

> If so, HOW? ;)


I expect that you can use any of the following:

· Slackware's boot loader to boot Slackware or chain load Windows's
boot loader.
· Windows' boot loader to boot Windows or chain load Slackware's boot
loader.
· Use a 3rd party boot manger to chain load Slackware or Windows.
John Forkosh (01-06-20, 03:16 AM)
notbob <notbob> wrote:
> OK. I'm ready to try.
> I've got an W10 box, but I wanna get back to Slackware,
> yet keep the W10 stuff fer the "media" stuff it can do,
> so well.
> It's an HP Slimeline Desktop PC 270-p0xx box with
> a i3-7100 gen 7 box (64 bit) with 8G RAM and a
> SATA 1T HDD (Toshiba DT01ACA100) HDD (?).
> I'll use a stock 14.2 d/l --full install-- to put on it.
> Will it work? If so, HOW?
> nb


I've installed slackware dual-boot on about half a dozen
boxes that came with win7-10 natively installed. No problem,
but it's always somewhat of a risk that you'll trash win.

o First, boot into the bios setup, navigate to the security screen,
and disable secure boot, which is often change the os to "other".
o Second, boot windows and defrag it -- google "defrag windows",
or similar, for instructions -- you've got to get an administrator
command prompt window, and type the right command(s). I forget
exactly, and always just google it to figure it out. Then defrag
again -- make sure window's defragged.
o Third, boot from a gnuparted (or similar) usb stick, and shrink
the windows partition, leaving at least a few tens of GB's above
the reported minimum -- as much extra as you think you might want.
o Fourth, use the freed space to create one or more linux partitions,
swap, etc. And I usually create an extra ntfs partition for windows,
for extra stuff or just for safe linux<-->windows sharing,
without directly writing to the win partition from linux.
o Fifth, now boot your slackware install, and proceed as usual.
It should immediately say it's detected a (u)efi partition,
and you should accept the elilo option it suggests. And after
the full install, also accept the suggestion to add an efi entry
rather than installing lilo.
o Done. When you reboot, it should default boot into slackware.
To boot windows, figure out which key to press during post
to get the uefi boot menu, which will give you the choice of
windows or slackware.
Chris Elvidge (01-06-20, 12:19 PM)
On 06/01/2020 01:16, John Forkosh wrote:
> Third, boot from a gnuparted (or similar) usb stick, and shrink
> the windows partition, leaving at least a few tens of GB's above
> the reported minimum -- as much extra as you think you might want.


I would recommend booting to Windows to do this step.
Windows knows whether there are unmovable files in its partition.
Disable hibernate and swap (and reboot) before doing the shrink, too.
Grant Taylor (01-06-20, 05:55 PM)
On 1/6/20 3:19 AM, Chris Elvidge wrote:
> Windows knows whether there are unmovable files in its partition.


Save for the $MFT and related NTFS indexes / files, I'm not aware of any
files that are truly unmovable.

All of the files that most Windows utilities won't move are because
Windows has them open and locked. Thus most things can't touch, much
less move, them. This tends to not be an issue when booted from
something other than Windows.

> Disable hibernate and swap (and reboot) before doing the shrink, too.


PageDefrag is probably a worth while idea too. (I used to have it run
on every boot.) Defrag and / or Contig is probably a good idea.
Joe Rosevear (01-19-20, 02:02 PM)
notbob <notbob> wrote:
> OK. I'm ready to try.
> I've got an W10 box, but I wanna get back to Slackware, yet keep the
> W10 stuff fer the "media" stuff it can do, so well.
> It's an HP Slimeline Desktop PC 270-p0xx box with a i3-7100 gen 7 box
> (64 bit) with 8G RAM and a SATA 1T HDD (Toshiba DT01ACA100) HDD (?).
> I'll use a stock 14.2 d/l --full install-- to put on it. Will it
> work?
> If so, HOW? ;)
> nb


Well, I do it this way...

I installed a full Slackware 14.2 (32bit) distribution to a 23GB
partition of a 32GB USB 3.0 Samsung Bar flash drive. I also made a 1GB
swap partition

I labeled the root and swap partitions, and I changed the fstab to
reference those labels.

You will also need an initrd.gz file.

I installed Grub2 to the flash drive's MBR. The grub.cfg file needs to
reference the initrd.gz file and the root partitions's label.

I press F9 when booting to choose the boot device. Some computers use
other keys to select the boot device. Alternately you can change the
boot order to boot first from the flash drive if it is present,
otherwise boot from the hard drive (Windows).

I need to explain that I made a change (using rsync) which resets the
cache (actually the whole /home/student directory--see below) to a
fixed starting point every time you boot the computer. And I reboot
the computer at least daily. This keeps the cache from growing too
large for the 23GB partition. It works well. It is nice to have a
clean cache. Also because it restores the whole user directory I can
configure Chromium's tabs, window size, and settings, and those
configures will not change permanently until I choose to do so.

I do my Internet browsing as user "student". I have another user (joe)
that I use for most everything else. User joe has a normal directory--
it is not reset on each boot. The home directory for user joe lives on
a different flash drive. This is helpful to keep my data separate.

By the way, student's home directory is on a ram drive. This reduces
the write activity to the flash drive. I also used "noatime" in the
fstab, and turned off journaling and set the check interval.

This may sound a little complex, but it works well, and it demonstrates
some things that are not widely known:

1. A USB 3.0 flash drive is a suitable replacement for a hard
drive.

2. 23 GB is enough. I just checked. My root partition is 59%
full.

3. You can keep a full version of Slackware on a flashdrive and use
it with various computers.

I hope this information helped--give it a try and let me know how it
goes!

-Joe
Aragorn (01-19-20, 07:46 PM)
On 19.01.2020 at 12:02, Joe Rosevear scribbled:

> A USB 3.0 flash drive is a suitable replacement for a hard
> drive.


Not if you're going to be writing to it often — as in "frequency",
rather than "quantity". USB flash drives generally don't support TRIM
operations, so if you write to it a lot, then the device is going to
wear out pretty quickly.
Joe Rosevear (01-19-20, 11:30 PM)
Aragorn <thorongil> wrote:
> On 19.01.2020 at 12:02, Joe Rosevear scribbled:
> Not if you're going to be writing to it often ? as in "frequency",
> rather than "quantity". USB flash drives generally don't support TRIM
> operations, so if you write to it a lot, then the device is going to
> wear out pretty quickly.


You are right, I'm sure. But that hasn't stopped me from using a
flashdrive as a replacement for a hard drive. So far I've had no
trouble. Perhaps the steps I took to reduce the number of writes to
the device helped. I wrote in my last post:

By the way, student's home directory is on a ram drive. This reduces
the write activity to the flash drive. I also used "noatime" in the
fstab, and turned off journaling and set the check interval.

So it definitely is not an "equivalent" replacement for a hard drive.
Let's compare:

feature flash drive hard drive
------- ----------- ----------
low cost v
high capacity v
high writes v
long shelf life v
easily portable v
high speed v

Did I get this right? By the way I use a pair of 500 GB hard drives
for my backups. (I rotate one off-site.) Hard drives work well for
that purpose, and they work well for running Slackware. I have found,
however, that a flash drive also works suitably well for running
Slackware, and that is what I wanted to share.

My use of Slackware on a flash drive in this way solves (for me,
anyway) the dual boot problem. My wife and I share a computer. She
likes MS Windows. So I made a bootable flash drive with Slackware on
it. We keep it by the computer. When I want to run Slackware I just
put in the flash drive and boot. When I'm done I shut down and remove
the flash drive. To run Windows, just boot without the flash drive.

I offer this non-tradional method as an option in response to the OPs
request for information about dual booting.

-Joe
Ned Latham (01-20-20, 12:02 AM)
Joe Rosevear wrote:
[..]
> the flash drive. To run Windows, just boot without the flash drive.
> I offer this non-tradional method as an option in response to the OPs
> request for information about dual booting.


Your /etc and /var directories are targets of system writes, which means
you should move them off the USB drive, and they need to be persistent,
which means the RAM drive isn't suitable: I suggest you make a small
partition for them on the computer's HD.

Though frankly, I don't see why you want to avoid multiple booting
off the HD: it's dead simple, as reliable as your HD, removes the
fiddling that the USB stick requires, and gives you an immediately
accessible rescue system for that Micro$oft crock of shit.
Aragorn (01-20-20, 02:25 AM)
On 19.01.2020 at 21:30, Joe Rosevear scribbled:

[..]
> easily portable v
> high speed v
> Did I get this right?


No, not completely. HDDs have a much longer shelf life than flash
memory. A flash-based storage device that hasn't been used for about
two years might start losing its data. The exact shelf life also
depends on the quality of the product, of course.

SSDs are relatively affordable nowadays — unless you're going for
the really high-capacity ones — and they are much faster and more
durable than USB sticks. Between the overprovisioning and the periodic
use of TRIM, you can get a very decent life out of them too — comparable
to enterprise-grade HDDs, even — but with much higher speed.
Joe Rosevear (01-20-20, 03:17 AM)
Ned Latham <nedlatham> wrote:
[...]
> Your /etc and /var directories are targets of system writes, which means
> you should move them off the USB drive, and they need to be persistent,
> which means the RAM drive isn't suitable: I suggest you make a small
> partition for them on the computer's HD.


So that's why I haven't put those directories in the RAM drive. I
don't intend to prevent all writes to the flash drive, just what works.
Your suggestion is good, but would kill the portability.

> Though frankly, I don't see why you want to avoid multiple booting
> off the HD: it's dead simple, as reliable as your HD, removes the
> fiddling that the USB stick requires, and gives you an immediately
> accessible rescue system for that Micro$oft crock of shit.


Different strokes for different folks. What you do is great. I have
fooled around with dual booting off the HD. Very nice!

It's more of an attraction than an avoidance. I'm attracted to the
method I use for other reasons, and it just so happens to also provide
handy dual booting.

-Joe
Ned Latham (01-20-20, 04:18 AM)
Joe Rosevear wrote:
> Ned Latham wrote:
> [...]
> So that's why I haven't put those directories in the RAM drive. I
> don't intend to prevent all writes to the flash drive, just what works.
> Your suggestion is good, but would kill the portability.
> Different strokes for different folks. What you do is great. I have
> fooled around with dual booting off the HD. Very nice!
> It's more of an attraction than an avoidance. I'm attracted to the
> method I use for other reasons, and it just so happens to also provide
> handy dual booting.


Gotta agree with that. Essentially, you could be carrying a Slackware
system around in your fob pocket. Could be very handy indeed.

In fact, I'm thinking "the ultimate portable test machine".
Henrik Carlqvist (01-20-20, 08:59 AM)
On Sun, 05 Jan 2020 19:10:39 +0000, notbob wrote:
> I've got an W10 box, but I wanna get back to Slackware, yet keep the W10
> stuff fer the "media" stuff it can do, so well.


Of course dual booting is possible, but will it be the best solution? In
my experience a dual boot installation will end up with one OS being used
more than the other and the other is almost only occupying HD space which
could have been to more use to the preferred OS.

Instead when having the need to run more than one OS I prefer to use
virtual machines like qemu. In my experience it is a lot more convenient
to start another virtual machine to run an application which requires
another OS than to reboot your entire machine to run that application.

regards Henrik
Joe Rosevear (01-21-20, 01:11 AM)
Ned Latham <nedlatham> wrote:
[...]
> Gotta agree with that. Essentially, you could be carrying a Slackware
> system around in your fob pocket. Could be very handy indeed.
> In fact, I'm thinking "the ultimate portable test machine".


Right. I use it for testing, for wiping hard drives of old computers,
and for installing Slackware to old (or new) computers. The
interesting thing about this modified Slackware on a flash drive is
that it also runs great when installed to a hard drive. And I have
placed a script on the flash drive which does the task of installing to
a target drive, whether it's a hard drive, flash drive, internal or
external.

It does the install using rsync so it runs fast, and it does the whole
job, allowing for a few places where it prompts the user to do manually
some things that were too difficult for me to code. In this manner it
does the following (in many instances allowing you to decline the
operation) in two boots.

-First boot--you boot Slackware on a partition that contains a
specially made /boot/tool dir. This can be, but doesn't have to be
one of my specially made bootable flashdrives. Then from inside
/boot/tool you run "./up1-stc". This is a symlink to the install
script /boot/tool/uptask-stc.

It wipes the MBR of the target device, runs parted, runs mke2fs and
mkswap, turns off journaling, sets up periodic file system checks,
installs Grub2, runs rsync to install the Slackware system, and
customizes the fstab and grub.cfg files so that they both refer
correctly to the label names of the swap and/or root partitions.

-Second boot--you boot Slackware on the target partition without
using the default "login=auto" boot parameter. Then you run
"./up2-stc" this time from inside the /boot/tool directory of the
target partition. It also is a symlink.

It prompts you to run netconfig, runs ssh-keygen on root, populates
an initial /home/student in the RAM drive, then prompts you to login
as student in another console (which starts X) and make needed
customizations, runs ssh-keygen on student, and stores the
/home/student dir in a persistent location.

Then the target is ready to boot and use normally. As I said the
target can be a bootable flash drive or the hard drive in a computer.

So perhaps it is the ultimate portable test machine (thanks for saying
that!), but that wasn't my intention when I made it.

-Joe

Similar Threads