IRC log of #novawebdev for Monday, 2023-12-04

*** jelkner has quit (Quit: Leaving)12:11
*** tboimah has quit (Read error: Connection reset by peer)12:35
ubuntouristtboimah, hi. Sorry I'm late.e14:18
tboimahGood morning Mr Cole14:18
mulbahGood morning14:18
ubuntouristhi mulbah sorry i'm late.14:18
mulbahOkay no problem14:18
ubuntouristI'm also sorry I haven't prepared anything. But I was planning to talk a bit about what "boot" means.14:19
ubuntouristFirst, do either of you have progress to report or questions to ask?14:20
tboimahyes14:21
ubuntouristtboimah, go ahead14:21
tboimahI have install the virtual machine manager and i am now trying to install some os on it14:21
tboimahand i am almost finish with the page that talk about the server14:23
tboimahACTION done14:23
ubuntouristtboimah, good to know.14:23
ubuntouristmulbah, anything from you? Questions? Progress?14:24
mulbahYeah progress14:24
mulbahI have been reading the book and writing down some questions and answering them 14:25
mulbahthe same tboimah said 14:25
ubuntourist(I didn't get around to looking at specifics of BIOS verses UEIF.)14:25
ubuntouristmulbah, good to hear.14:26
mulbahthat i will soon finish with the page that talk about server14:26
ubuntouristI wanted to talk a little about "booting" and it relates to BIOS / UEFI stuff.14:28
ubuntouristComputer chips are small and fast, but unfortunately expensive to produce.14:28
ubuntouristAnd, early chips needed electrical power to "remember" anything. If you turned the machine off,14:29
ubuntouristor cut the power, anything data on a computer chip would become random  garbage.14:30
ubuntouristIn contrast, magnetic storage --- magnetic tape and magnetic disks -- were inexpensive, and didn't14:31
*** mulbah has quit (Remote host closed the connection)14:32
ubuntouristneed power to "remember" what was stored on them. But they were big, slow, and inefficient.14:32
ubuntouristSo, manufactuers needed to compromise: How do you balance the need for speed with the need for permanence?14:33
ubuntouristYou can make chips with data burned into them that can never be changed. So, you could have an expensive chip with an14:34
ubuntouristapplication burned in, and that application would locate data on a tape or disk, read it into memory chips, and then start14:35
ubuntouristusing what was loaded into memory.14:35
ubuntouristIn Python, you have both used the "import" statement, right?14:36
mulbahYeah14:37
mulbahto import module14:37
ubuntouristOK. So that is -- very roughly -- a similar idea: Imagine that your program was burned into a chip, and could never be changed.14:38
ubuntouristBUT, the module that you were importing was NOT burned into a chip, and you could edit it and improve it.14:38
ubuntouristThe word "boot" comes from an old story or joke. Hold a sec...14:40
ubuntouristThe story or joke refers to men who were trying to climb something impossble to climb. But the joke is,14:42
ubuntourist"Well, if they could reach down to their boots and pull the bootstraps hard, then they could 'levitate'."14:43
ubuntouristIt's a silly, nonsense idea called "pulling yourself up by your own bootstraps".14:44
ubuntouristEarly in the history of computers, someone came up with the expression "bootstrap loader" to describe the process of14:45
ubuntouriststarting an operating system: A tiny program, burned into a small chip would read  a larger program from tape or disk --14:45
ubuntouristlike importing a module -- and then use that module to read an even larger module from the tape or disk, and then use THAT module14:46
ubuntouristto read bigger and more modules iinto memory. The computer was "pulling itself up by its own bootstraps" or "booting".14:47
ubuntouristIn the present, disks are becoming faster and smaller, and many aren't really even disks any longer, although we still use the word.14:48
ubuntourist(Early disks were really much more like phonograph records: They spun and had a movable arm that woul position itself over the magnetic impulses14:49
ubuntouristin a way that is similar to a phonograh needle positioning itself over a grove etched in vinyl.)14:50
ubuntouristEven though the difference between traditional hardware chips and "hard disks" is shrinking, the process of booting is still 14:51
ubuntouristsimilar to ancient times.14:51
ubuntouristFirst, the computer's burned in program performs a quick self-check to see if memory and other components are working as they should.14:52
ubuntouristThis is referred to as the POST -- Power On Self Test14:53
ubuntouristThen, it starts the boot process of reading a program to tell it what to do next.14:53
ubuntouristIMPORTANT: At this stage, the computer does not understand what a file is, or what a directory is. 14:54
ubuntouristAt this point in the boot process, it is doing something purely mechanical. Think of gears in a car or a bicycle or some other mechanical14:55
ubuntouristdevice.14:56
ubuntouristFIrst BIOS then a little bit about UEFI.14:56
*** jelkner has quit (Quit: Leaving)14:57
ubuntouristHold a sec. I want to find a good picture to link to...14:57
ubuntouristhttps://en.wikipedia.org/wiki/Cylinder-head-sector14:58
ubuntouristCylinder, head, and sector. Sometime referred to as cylinder, sector and track.14:59
ubuntouristIn your studies -- both mathematics, and world geography, you've probably learned about three dimensional 15:00
*** tboimah has quit (Ping timeout: 480 seconds)15:00
*** mulbah has quit (Ping timeout: 480 seconds)15:00
ubuntouristcoordinate systems: X, Y, and Z in mathematics, latitude, longitude, and altitude in world geography.15:01
ubuntouristIn computers, the three coordinates are cylinder, sector and track or cylinder, head and sector.15:01
*** mcssguest_ has quit (Ping timeout: 480 seconds)15:01
ubuntouristACTION waits to see if tboimah and mulbah are on or off. Lots of quit / join / quit messages...15:03
ubuntouristtboimah, mulbah both still here?15:03
tboimahwe are on15:03
mulbahwe are on15:03
ubuntouristOk.15:04
ubuntouristSo. when BIOS finishes POST, it still doesn't know what a file is. But it does know very primitive instructions15:04
ubuntouristto position a mechanical arm over a specific cylinder, move inwards to a concentric ring, and read data from a "pie slice" 15:05
ubuntouriston the hard disk. In other words, it finds a very  specific location, based on three physical coordinates, and tries to read computer instructions 15:06
ubuntouristfrom that. It is not looking for a file name, because it does not know what a file is. It only knows "Position a mechanical arm to X, Y and Z, and start reading15:07
ubuntouristmagnetic pulses, and hope that those are statments that can be acted on.15:08
ubuntouristUnderstand so far?15:08
tboimahsure15:09
ubuntourist(Take a look at the Wikipedia article later for a better understanding.)15:09
tboimahgetting the concert small small15:09
mulbahalright15:09
ubuntouristOK. So that brings us to what you're doing now:15:10
ubuntouristOh. Before I go there: One more thing. We used to have just two concepts:15:11
mulbahWhat do you means Mr. Cole?15:11
ubuntouristHardware -- which were either chips that were permanently programmed and unchangable, or were very changable but needed electical power all the time,15:12
ubuntouristSoftware -- which was stored on magnetic media. Slow to read and write, but able to stay the same without electical power.15:13
ubuntouristNow we have something between hardware and software -- firmware.15:13
ubuntouristModern BIOS and UEFI are firmware.15:13
ubuntouristSaving firmware to chips ("flashing" the chips) is slow. But reading the fimware is "reasonably fast".15:15
ubuntouristSo, firmware does not change often due to the slowness and difficulty of "flashing the chips".15:15
ubuntouristSo. Your virtual machine is software that SIMULATES firmware.15:16
ubuntouristWhen you use virt manager to create a virtual computer, it sets up a file on your hard disk that has firmware that15:17
*** mulbah has quit (Remote host closed the connection)15:17
ubuntouristreads from a virtual, unformatted hard disk. Again, IMPORTANT: The virtual computer firmware (BIOS / UEFI) does NOT know what15:18
ubuntourista file is. It only knows X, Y, Z / latitude, longitude, altitude.15:18
ubuntouristWhen you are trying to load an operating system onto a real physical computer or a virtual computer, you must use a "file that is not really a file"15:19
ubuntouristIt is a "disk imaage". A disk image is a "snapshot" of a hard disk that has a special cylinder, head and sector called the "boot sector".15:20
ubuntouristThe boot sector has the module that tells the computer a lot of things. One of the important functions in the boot sector module15:21
ubuntouristtells the computer what a file and directory are. It is like drawing borders and naming countries on our latitude, longitude and altitude system.15:22
ubuntouristThere is another special area of the disk called the "File Allocation Table" (FAT) that keeps a journal of which cylinders, sectors and tracks are currently15:23
ubuntouristin use (files containing data) and which are unused ("free disk space").15:24
ubuntouristIMPORTANT: There are several DIFFERENT ways to do disk allocation -- the way that cylinders, sectors and tracks can be interpreted as files. 15:25
ubuntouristThese are called "filesystems". Linux understands several different file systems. Some file systems are good at speed. Others 15:26
ubuntouristare good at efficient use of space. And others are good at redundancy and preservation -- making sure that if a file is damaged, the computer can make an15:27
*** mulbah has quit (Remote host closed the connection)15:27
ubuntourist"educated guess" about what information went missing.15:28
ubuntouristThe average Linux user today uses the "ext4" file system. See15:29
ubuntouristhttps://en.wikipedia.org/wiki/Ext415:29
ubuntouristSo. When you are loading up your virtual machine, the disk image contains a boot sector, and a File Allocation Table with a "file system" -- probably "ext4"15:30
ubuntouristand, with those two pieces of information (boot sector and fie system FAT) the rest of the disk image file looks like something you're already familiar with:15:31
ubuntouristdirectories and files.15:32
*** tboimah has quit (Ping timeout: 480 seconds)15:32
ubuntouristREMEMBER: ISO disk images, even though they look like ordinary files, are NOT ordinary. they are like ZIP files or tarballs but the special parts 15:33
ubuntouristare the boot sector and the file system FAT that tells the computer how to break the file into "real" files and directories.15:34
ubuntouristYou CANNOT just "copy" an ISO to another computer and expect to read the files in it. You cannot unpack it or unzip it or expand it. It is a special thing that must be15:34
ubuntourist"written" to a hard disk in a special way. (Your virtual machine software will know how to do this.)15:35
ubuntouristAnyway, that's all I wanted to talk about today:15:36
tboimahokay that was great15:36
ubuntouristAfter installing virt manager and creating an empty virtual machine, you need a special ISO disk image to be put on the virtual hard disk. This is like15:37
ubuntouristformatting a hard disk and copying a bunch of files all at once. Once those steps are finished, you can "boot" your virual machine.15:37
ubuntouristWhen you boot your virtual machine you will have a "virgin" operating system that you can destroy without worry.15:38
tboimahalright15:39
ubuntouristIf somehing breaks, you just delete the virtual machine, create a new virtual machine, and reload the ISO disk image to get back to a "virgin opeating system".15:39
*** sysadmin_ has quit (Ping timeout: 480 seconds)15:39
ubuntouristI don't know yet if the book will have you do it, but we might try several different Linux operating systems using different ISO disk images.15:40
ubuntouristAnd, as systems administrators, eventually, you may want to create your own disk images.15:41
ubuntouristFor example, let's say you're running a school's computer center. for four years. 15:41
ubuntouristEventually, you will become tired of saying "apt install most", "apt install tmate", "apt install bla-bla-blah", "useradd sysadmin", "vim /etc/profile", ...15:42
ubuntouriston every single machine again and again.15:43
ubuntouristEventually, you'll decide "I always want these packages, these users and these configurations on ALL of my lab's computers."15:43
ubuntouristWell, once you have something that you think is the "perfect" set up. you can create an ISO disk image snapshot of your perfect machine,15:44
ubuntouristand just load the ISO disk image onto every computer. It will erase all of the old information on the computer and set up a complete environment that is identical15:45
ubuntouristto the environment on your perfect computer.15:45
tboimahwow15:45
ubuntouristThis is also a good backup. Suppose one of your students -- or teachers -- completely mess up, and delete everything or edit files they shouldn't edit.15:47
ubuntouristWell, there is no way to recover their data and prgrams if no one is backing them up regularly -- we'll talk about scheduled backups later. BUT, you can at least "reset" the computer15:48
ubuntouristback to a "known working state" by using the ISO to erase and restart from scratch. And because you know the ISO you're working with, you will know "Oh, yes: most and tmate are already installed, 15:49
ubuntouristand these aliases and shortcuts are already configured for every user."15:50
ubuntouristAnd NOW, I'm REALLY finished talking for today. ;-)15:50
tboimahOkay thanks for today 15:51
tboimahhave a nice day15:52
ubuntouristGood luck getting your ISO loaded onto the virtual machine.15:52
ubuntouristBye for today.15:52
*** ubuntourist has quit (Quit: Leaving)15:52
*** tboimah has quit (Read error: Connection reset by peer)15:52
*** tboimah has quit (Read error: Connection reset by peer)16:00
*** scooper has quit (Ping timeout: 480 seconds)21:27
scooperFkoikoi21:28
fkoikoiyes scooper21:28
scooperDid you tried attempting the question on your own???21:28
scooperand did you also comment those work that was done in the lab too???21:29
fkoikoino but I will do that after this21:29
scooperI m about to leave from here now...21:30
scoopersee you tomorrow21:30
scooperACTION signing up21:30
*** scooper has quit (None)21:30
*** fkoikoi has quit (Quit: Leaving)21:30
*** shmohamud has quit (Remote host closed the connection)21:48

Generated by irclog2html.py 2.17.3 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!