LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 09-07-2020, 05:33 PM   #1
ul7
Member
 
Registered: Jan 2020
Posts: 115

Rep: Reputation: 30
Optimal install templates for testing Slackware? (discussion/post)


I want to do more testing with Slackware now that I'm getting more used to it in my first week (still have a long way to go). This is mainly a theoretical discussion / suggestion thread. Opinions are welcome, and I would love to hear multiple ideas. As of right now I using VMWare: Workstation Pro to experiment with Slackware. Please keep that in mind during your feedback, although I still would appreciate hosted setups as well (they may not differ as much).

Mainline question:
What would be an ideal setup from a clean install for testing purposes? Testing in this case would be for programming.
Sub-questions that feed into the mainline question include:
  1. cfdisk vs. fdisk (gpt/dos/sun/sgi < differences in these?)
  2. Partitions and sizes (ideal strategies for allocating directories)
  3. Swap and it's viability (16GB of RAM / 4 cores is what I'm allocating)
  4. Additional services I should add aside from the default? (I'm talking about setup mode, where there are additional services and packages you can add before installing the system.)
I believe that would cover my curiosity for quite some time. I want to thank the entire Slackware family for being super supportive and encouraging me to stay the course! Thank you!!

Last edited by ul7; 09-07-2020 at 05:35 PM.
 
Old 09-07-2020, 09:45 PM   #2
frankbell
LQ Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,329
Blog Entries: 28

Rep: Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142
I always use cfdisk because I understand it. I'm an old DOSsie and cfdisk is very like DOS fdisk. It's never given me any issues. I've never bothered to understand fdisk because I've never had to.

I always create a separate /home partition, regardless of the distro. Generally, I've found that a 25-30 GB root partition is more than roomy enough for everything else, and I allocate the rest of the HDD to /home. The only exception I can think of is that, if you plan to do something special in /opt, like run XAMMP and test websites, you may want to either enlarge /root or put /opt on a separate partition adequate to meet the needs for what you want to do.

With 16 GB RAM, I would allocate no more than 4GB swap, maybe less. On this machine, I have 16GB RAM, 4GB swab, and run various VMs regularly (a VM of Endeavor Linux is running right now), and swap is hardly ever touched. The only exception I know of is this: if you wish to use hibernation (I do not), swap should be slightly larger than RAM, because, in hibernation, the image is stored to swap. I know that some persons no longer use a separate swap partition if they have lots of RAM, but I like the predictability of a fixed-size swap. And HDD space is cheap these days.

As regards install, I just do a full install. If I'm installing on a desktop, I usually set a static ip address.

Just a few thoughts.

Last edited by frankbell; 09-07-2020 at 09:47 PM.
 
1 members found this post helpful.
Old 09-08-2020, 01:17 AM   #3
RadicalDreamer
Senior Member
 
Registered: Jul 2016
Location: USA
Distribution: Slackware64-Current
Posts: 1,816

Rep: Reputation: 981Reputation: 981Reputation: 981Reputation: 981Reputation: 981Reputation: 981Reputation: 981Reputation: 981
If you have a big hard drive I'd allocate ~100G to root so you don't have to worry about running out of space. That takes care of /tmp (where packages are built) and whatever you install in /usr and /opt.

Having /home on a separate partition is sweet. I have different partitions for files like music, books, games (Steam Library), and movies, etc so whatever happens to root my files are unaffected.
 
Old 09-08-2020, 02:58 AM   #4
madridsecreto
Member
 
Registered: Apr 2018
Location: Madrid
Distribution: Slackware64 -current
Posts: 34

Rep: Reputation: 30
Quote:
What would be an ideal setup from a clean install for testing purposes? Testing in this case would be for programming.
All answers to that question are probably subjective and they'd depend on particular circumstances, like what kind of programming you will be doing (systems, web), or what language you will be using.

Quote:
cfdisk vs. fdisk (gpt/dos/sun/sgi < differences in these?)
I've used both and I prefer cfdisk. It's easier to learn and use and, as I've read somewhere, fdisk has certain limitations regarding disk size.

As for the label types, gpt is for drives bigger than 2 TB or that use UEFI, and dos is for everything else. Unless someone more knowledgeable contradicts me, you can safely ignore the rest.

Quote:
Partitions and sizes (ideal strategies for allocating directories)
As others have pointed out, having a separate /home partition is a must. The rest depends on your needs.

When I started with Slackware, I followed howtos and only had a root (/) partition, /boot and /usr/local, but that was not a good setup. Right now I have a /boot partition (1 GB), root (/, 80 GB), /root (10 GB. This is where I keep my slackbuilds), /usr/local (10 GB. I keep there small personal programs that don't need installation and symlinks to TexLive files), /var/log (10 GB), /var/www (50 GB. That's where my web projects are), /opt (150 GB. I keep here whatever I feel does not belong under /, like Java, TexLive or crafty). The rest of the space (around 600 GB) is occupied by the /home partition.

Most of them are virtually empty, because I allocated much more space than they actually needed. But why not? I have disk to spare.

Anyway, you probably don't need the same partitions that I use (if you don't do web programming, you would not be using /var/www, for instance). Your own partitioning style will come to you with time. The question I ask myself when I partition is this: “What would I want to keep if I had to reinstall?”

Quote:
Swap and it's viability (16GB of RAM / 4 cores is what I'm allocating)
I have 8 GB of RAM and another 8 of swap. I could probably get away with less, because, with the exceptions of browsers and Emacs, I mostly use console applications. My consumption very rarely goes beyond 2 GB of RAM.

That said, if you use VMs or play videogames, you probably need more RAM than me and more swap. My advice is that you go crazy: swap is cheap. It is disk space, after all. Use as much as you have RAM.
Quote:
Additional services I should add aside from the default?
Actually, that's not the right question, but “Additional services I should disable?” The less daemons you have running around, the better. Do you need sshd? Probably not, even if you do use ssh. Do you need mysqld or httpd? Maybe, but maybe not.

So, my advice here is: Make sure you know what each of them does and disable those you don't need.

Hope this helps.

Last edited by madridsecreto; 09-08-2020 at 03:02 AM. Reason: I got a detail wrong, I think.
 
Old 09-08-2020, 09:16 AM   #5
ul7
Member
 
Registered: Jan 2020
Posts: 115

Original Poster
Rep: Reputation: 30
Yes this is great feedback for gaps in my knowledge. I am OCD about fundamentals, so this is a great post for gaining insight on the approach of understanding the Linux OS. Trying to learn things like: how it's all pieced together, how each element works with each other are all things I have to re-learn again. Coming from an all Windows and no Linux background, I am re-learning how to ride a bike. I don't believe in shortcuts, and I tend to be very technical but competitively humble. Thanks for experienced opinions!
 
Old 09-08-2020, 05:17 PM   #6
juliusse
LQ Newbie
 
Registered: Aug 2020
Location: where the wind goes
Distribution: Slackel
Posts: 9

Rep: Reputation: Disabled
My two cents.
I know some are going to throw me rocks, but I don't care.
Even if I use to in the past, I now never have more separate partitions than the strict minimum.(only root, swap, and efi boot if needed)
I have an external HD for backup, physical separation. I find it more efficient and simple, in opposition to 36 partitions which are for the vast majority empty.(but it's my way to do)
All testing/programming/specific work is made in virtual machines.
For the sub-questions:
1- cgdisk Vs fdisk vs cgdisk vs other, try and make your own opinion, keep the one you are the most comfortable with.
3- with 16GB RAM, 4GB swap is good. Later you will learn to change swap parameters if you want.
4-For what I think, it's always better to add something if needed than having to remove something unnecessary.
 
Old 09-08-2020, 06:03 PM   #7
gouttegd
Member
 
Registered: Nov 2019
Location: London, UK
Distribution: Slackware
Posts: 92

Rep: Reputation: 161Reputation: 161
Quote:
Originally Posted by ul7 View Post
cfdisk vs. fdisk (gpt/dos/sun/sgi < differences in these?)
I typically use gdisk, but the choice of the tool does not really matter (you can use whatever tool you find easier to use). What really matters is the type of partition (GPT for me as I use UEFI).

Quote:
Partitions and sizes (ideal strategies for allocating directories)
My standard advice is to forget about physical partitions and use LVM. That is, create a single physical partition covering the entire disk and use it as a LVM physical volume. Then split the volume into as many logical volumes as you need/want.

Pros:
  • You don’t need to worry about running into some arbitrary limits regarding the number of partitions (e.g. if you use DOS partitions, you don’t have to play with primary and extended partitions).
  • If you realize after a while that one of your logical volumes is too small, you don’t have to redo your partitionning from scratch; just extend the volume as needed—in most cases you don’t even need to reboot to do that.
  • If you run out of unallocated space on your physical volume, you can add another physical disk to the volume group and extend your logical volumes on it.

Cons:
  • You need an initrd to boot (which is not a big deal IMHO).
 
Old 09-08-2020, 09:20 PM   #8
ul7
Member
 
Registered: Jan 2020
Posts: 115

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by juliusse View Post
My two cents.
I know some are going to throw me rocks, but I don't care.
Fret not. If this does become a nerd-fest of fighting and arguing, I will make sure it gets shut down. The OP clearly states the vibes of the thread discussions/post. It's there to talk/discuss. Thank you for being awesome!
 
Old 09-09-2020, 02:19 AM   #9
truepatriot76
Member
 
Registered: Apr 2014
Location: California, USA
Distribution: slackware64-current
Posts: 231

Rep: Reputation: 195Reputation: 195
I like to fine tune my hardware setup with primary partitions for a bit of granularity & performance

/var --> slower hdd -- log files/variables
/tmp --> nvme -- speed up the build process
/ --> nvme
/home --> nvme
/repo --> hdd --local repository and backup
/swap --> negligible space - nvme for speed

Beneficial if you have, or want to conserve limited ssd space.

Last edited by truepatriot76; 09-09-2020 at 02:32 AM.
 
Old 09-09-2020, 06:58 AM   #10
chrisretusn
Senior Member
 
Registered: Dec 2005
Location: Philippines
Distribution: Slackware64-current
Posts: 2,973

Rep: Reputation: 1551Reputation: 1551Reputation: 1551Reputation: 1551Reputation: 1551Reputation: 1551Reputation: 1551Reputation: 1551Reputation: 1551Reputation: 1551Reputation: 1551
Quote:
Originally Posted by ul7 View Post
What would be an ideal setup from a clean install for testing purposes? Testing in this case would be for programming.
I'll just focus on the (less than) ideal setup for a clean install I use. I say less than ideal, because hardware is better than a virtual machine, though there are advantages over hardware with using a VM; snapshots. I have four Slackware VM's installed in VirtualBox. The host is this computer, using Slackware46-current with Alien Bob's ktown in place of KDE. The VM's are Slackware-14.2 (Wed Aug 5 18:46:42 UTC 2020), Slackware64-14.2 (Wed Aug 5 18:46:42 UTC 2020), Slackware-current (Sun Aug 30 18:11:18 UTC 2020), Slackware64-current (Sat Sep 5 19:27:47 UTC 2020). I keep them updated on an as used basis, that's ChangeLog.txt dates in parenthesis. I am actually updating the -current VM's as I type. I keep track by added the ChangeLog.txt date entry to the Description of the VM.

All of these VM's are installed with the recommended Full Install to a two partition hard disk, one Linux (30 GB), one Swap. (2 GB). I give them 2 CPU's, 2G of memory and use the Bridge Adapter setting for Network so the are assigned IP from the LAN.

Before I start a testing session I first make sure my VM is up-to-date with the latest ChangeLog.txt. Once that is done, I create a shapshot to save state of VM at that point. Once I am done with the testing session, I simply restore the snapshot to make that VM clean again and delete the snapshot.

Most of my testing is package building. I really helps to have a clean system for this. This is especially important when I have a SBo SlackBuld that fails on this computer running Slackware64-current; which is definitely NOT a clean system. I can test to see if it will build on a clean system. (A requirement for Ponce's SBo scripts not building on current thread.)

Quote:
cfdisk vs. fdisk (gpt/dos/sun/sgi [B]< differences in these?
It's really a matter of choice, I used fdisk for a long time, then switch over to cfdisk because it's a bit easier to use.

Quote:
Partitions and sizes (ideal strategies for allocating directories)
I've been doing this for a long time. I come from a Unix background. There was a time when I used a number of partitioning schemes. These day I make it simple. This is my current layout and what I use with all of my computers.
Code:
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda1        98G   26G   67G  29% /
/dev/sda3       818G  401G  376G  52% /home
Quote:
Swap and it's viability (16GB of RAM / 4 cores is what I'm allocating)
This computer has 8G of memory, I use a 2G swap. This is what's being using right now.
Code:
cat /proc/swaps
Filename                                Type            Size    Used    Priority
/dev/sda2                               partition       2097148 7692    -2
My laptop has 4G of memory with 2G swap partition. I hibernate this laptop daily with no issues. It's set to hibernate on lid close, when I do that, nothing outside of the desktop environment is running anyway. I've occasionally closed the lid with a spreadsheet or three open, no problems.

Quote:
Additional services I should add aside from the default? (I'm talking about setup mode, where there are additional services and packages you can add before installing the system.)
Depends on your needs. For me two "mandatory" services I always add during setup are rc.cups and rc.rcp. Other services that I add are rc.netd, rc.ntpd, and rc.smartd.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
DISCUSSION: Using Templates in OpenOffice Writer solveig LQ Articles Discussion 2 09-10-2007 10:54 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 10:54 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration