Way To Go - Finally

My special interest is computers. Let's talk geek here.
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

As an aside (because I'm not telling you the whole story in the above post) I tried this exact process a few weeks ago. Linux Mint at that time did something to my ASUS mobo that I have yet to figure out. I think it changed something in BIOS to force me to use UEFI. All the OS's previously installed work fine, but the boot order is no longer what it used to be. You know, you go into BIOS and say boot USB first, then the DVD, then the hard drive. I now have a mysterious bootable device called UBUTU and one of my three hard drives is mislabeled. The net result is that the system will not automatically boot into anything but Windows which is on a separate hard drive with it's own bootloader. I have to manually select which alternate drive to boot from, and they are not labeled correctly. I have no idea what that UBUNTU drive is or now to get rid of it. The only recourse is to set the BIOS back to it's factory defaults and see what happens. I could lose it all if that doesn't work right. So, now, I decided to make an image of Windows 7, which I have to do before Microsoft kills it anyway, and hope for the best. I really don't care if I need to reinstall all those Linux systems, but I can't afford to lose Windows 7. It now looks like I will have to do this reset before I can progress with Linux.
User avatar
Kellemora
Guardian Angel
Guardian Angel
Posts: 7494
Joined: 16 Feb 2015, 17:54

Re: Way To Go - Finally

Post by Kellemora »

If I had the time, I would try it to see what the hangup is.
Since you can install a Live OS on a Stick and have it work on any computer.
I'm wondering if the install is rewriting that boot area and that is what is messing things up.

I'm going to ask a dumb question here. Are you sure the USB stick itself is OK?
I bought a box of 6 32 gig USB sticks and 1 of them did not work at all, and one of them will only hold 16 gigs of data.
I guess I should expect that since the box of 6 was only like 19.95, hi hi.

I have a small 8 gig USB stick I carry in my pocket with my books on them to share with folks.
The last time I went to share them to someone, two whole folders were missing from the stick.
When I got home I checked the stick again and sure enough, they are gone, but the stick itself checked OK.
So I put those two folders back on it again.
It could be the person I had copy the files used the move command instead of copy command, although all he did was drag the folders to his desktop. A DRAG from one device to another is supposed to automatically be a Copy command unless you hold down the Ctrl Key. Oh well, no harm done since I caught it.

On another note, I will have to throw away my OLD digital camera. The largest SD card you can use in it is 1 gig.
My wife's Schmartz-Fone takes pictures that are higher resolution than it did anyhow.
Heck, my flip-fone probably does too, hi hi.

OH, one serious question here, Is a USB External SD Drive of any better quality than a USB Stick?
I'm also confused to the max. I see UDisk 32g USB 3.0 - 2TB Flash Drive in an ad for 9.99. When you open the ad it says it is 2 Terrabytes for 11.99 - However, right next to it, by the same maker is a 32g USB 2.0 for 10.29, both in metal cases.
While the USB External 2TB SD Drives are 60 to 100 dollars and some higher priced.

I'm not sure if my Silver Yogi has a 3.0 USB port, and I figure if something says it is 3.0 it won't work on 2.0.
User avatar
Kellemora
Guardian Angel
Guardian Angel
Posts: 7494
Joined: 16 Feb 2015, 17:54

Re: Way To Go - Finally

Post by Kellemora »

Whenever my boot sector gets messed up I simply use a Boot Repair Disk I keep in my fixit stack of CDs.
It usually fixes whatever went wrong.
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

Things have changed dramatically in the flash memory arena. Originally you could only rely on flash memory for a short period of time. I don't recall the exact numbers but something like 1000 r/w transactions would put you at the useful limit. The SSD on this ASUS tower is essentially a flash drive and has a few hundred terabytes of data logged as being written to it. It shows no significant losses when I run Crystal Disk Analyzer on it. I've been using it for a few years now and have no idea when it will give out. There are also three hard drives in the same tower. One is doing pretty well and the other two need to be watched. Fortunately they don't get used much but they all are approximately the same age. I expect the HDD's to give out before the SSD.

From what I read about the subject, there is a huge difference in the quality of USB memory sticks verses a USB external drive. The external drives can be considered permanent for most people, but not so with the sticks. It seems to me they would be both manufactured the same way, but apparently not. I have one external USB drive that I use to store images of my Windows systems. That one gets unplugged so that no power is applied for most of it's life. Both the tower and the laptop are using SSD internal drivers which seem to be as durable as mechanical drives, if not more so.

USB 3 is backward compatible with USB 2. The big difference is the speed, USB 3 being about ten times faster. If you plug the 3 into a 2 port you will lose the speed advantage. And, if you put 2 into a 3 port, you will not gain anything. It's the same old story that the data transfer cannot be any faster than the slowest link.

I'm posting this from a Linux distro called KDE Neon that is installed onto a USB 3 memory stick of 32GB capacity. I see no difference in response on this USB OS than I would see on the mechanical hard drive I'd normally use. That's pretty interesting given that the bus for USB 3 is not as robust as SATA. So they say. You can't prove it by me.
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Linux On A Stick

Post by yogi »

So, now let me tell you why I posted the above while I was using Linux on a stick. :mrgreen:

Just so you don't lose sight of the mission here, all I want to do is install Linux, any distro of Linux, onto a USB memory stick so that it will boot in the UEFI mode on any computer. You've talked to people who have done it and I have read dozens of articles from people describing how to do it. Thus, I am fairly confident it is possible.

You gave me a gold mine of information when you posted the Linux Mint forum tutorial regarding how to do exactly what I am striving for. In fact the article was so convincing that I didn't feel a need to test any of it out immediately. It looked well written and has at least 4 alternative methods that all appear logical and reasonable, if not highly technical. But, I spent a few weeks priming myself with the technical details. I waited until I finished all the honey-do tasks on my personal agenda because I figured it would take about an hour of dedicated time to concentrate on making the installation. As noted earlier, I picked what seemed to me the easiest of all the methods, and did in fact install Linux MInt 19.2 on a USB memory stick. It didn't go as smoothly as I'd anticipated, but it apparently did install.

The strategy for installing is simple. Create the ISO, then use that to install the system onto a target memory stick in the MBR format. Once that's done, boot the installed system and install the UEFI bootloader. That's it. Not really complicated when put in those terms. As of yesterday, I could not boot Linux Mint after I installed it. My heretofore faithful ASUS tower could not recognize the stick as having a bootable OS on it. I tried the same trick on the laptop and it did recognize the partition for booting UEFI, but, of course, there was no bootloader software in that partition yet. And, the laptop being GPT formatted would not recognize the MBR formatted boot sector on the stick. Thus, what appeared at first to be simple stalled in the middle of the process.

Being a well experienced troubleshooter of many years, I knew the source of the problem could be in any number of places. I've been blaming the poorly developed Linux version of UEFI for it's inability to perform as advertised, but it could be my hardware/firmware as well. I've had a little problem with the BIOS in the tower ever since I attempted to install Linux MInt onto a memory stick a couple weeks ago. But, after a lot of investigation and tweaking, I can say my BIOS works differently than it used to, but it is not broken. Plus, my BIOS isn't really BIOS. LOL it's UEFI simulating BIOS and always has been that way. I have it set to ignore the UEFI part of the EEPROM. This is important because it is mandatory to install Linux on a stick (this method anyway) in the BIOS/MBR mode. The partition table, however, needs to be GPT to enable UEFI in the second step of this process.

After not being able to boot Linux Mint, I verified that the partitions of the memory stick were populated with what I expected to be there. I verified the MBR format and the GPT partition table. All as it should be. I could understand why it won't boot in the laptop, but there is no reason for it to fail in the tower. So, like yourself, I began to wonder if maybe the USB memory stick is failing in spite of all indications saying it's not. The decision was made to pretend UEFI doesn't exist and to create a bootable USB stick version of Linux that is all MBR. To accomplish this I abandoned the idea of using Linux Mint - it's been suspect from day one. I chose KDE Neon because it is a minimalist system and not a Cinnamon desktop, plus it installs the nVidia drivers automatically if I ask it nicely.

The Neon ISO I downloaded was installed onto a clean (meaning no partitions) USB memory stick. The install GUI isn't what you see in Ubuntu, but it does all the same things. When it came time to set up the partitions, I did not choose to do it myself. I chose to let the installer do it automatically. All I needed to do was assure I was pointing to the correct hardware, which I was. It installed flawlessly, which made me feel better. Then I rebooted so that I can test out what I just created, and ... and ... and the first screen I got was an option to enter an encryption key. WTF is that? I'm trying to do this in MBR and now I'm being asked to set up a secure boot in UEFI. I did not even think it was possible to boot into UEFI on the tower because I disabled that function. Well, apparently Linux doesn't let small things like that bother it. It just changed what it wanted to and created a UEFI bootloader. While that might be the case, it will not boot on the laptop (which is all UEFI).

So, now I have a non-UEFI desktop computer that boots into UEFI operating systems. This might be fine in some other universe, but I'm here trying to make an MBR installation and the OS of choice is not doing it. Interestingly enough, Linux Mint will make an MBR installation, but will not boot in spite of it.

To answer your last question, I just proved that the memory stick can and does boot up Linux. It's not the format I want, but at least I can say the stick is still good. That's amazing considering how many times I've repartitioned it. Not sure where to go from here, but getting rid of UEFI from the tower seems like the first step.
User avatar
Kellemora
Guardian Angel
Guardian Angel
Posts: 7494
Joined: 16 Feb 2015, 17:54

Re: Way To Go - Finally

Post by Kellemora »

Well, I'm glad to hear you are making some headway, even if not in the manner you want it to be.

I did learn one thing myself, I cannot install the version of Linux Mint I have on a UEFI only computer.
Namely the new computer I bought for Debi with Win10 on it. It does not have BIOS either.
Although I think I can download a new Linux Mint for UEFI machines, but have not checked any further on that yet.

I can also do a test on my USB sticks, but the output given looks nothing like when I run a test on a HD.
On a HD it shows bad sectors if they exist, and after an attempt to fix the bad sector, will block it from use if it cannot be fixed.
Apparently SD cards work nothing like that. On a good stick, all you get is All Pairs Healthy plus an OK.
But if it has a couple of bad spots it will show something like 3 Bad Pairs data relocated successfully.
Not much info to go on, but it sounds like data is stored twice, and if one of those spots that save data go bad in a pair, it no longer uses that pair and moves the data to a good pair.
However, that is probably not at all how they work, hi hi.

I have read up on them a few times, but no article says how the data is stored, other than on NAND chips.
They do say each manufacturer has it's own way of insuring against data loss as the cards wear out.
But that was about it.
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

Any version of Linux Mint in the 19.x series will do both UEFI and BIOS. In fact that's the crux of my problems. The current method I'm trying to master needs a stick initially formatted for BIOS with an MBR. It seems that Mint has a mind of it's own and insists on creating a UEFI installation every frickin' time. Of course my MBR tower will not recognize such a scheme.

The three partition approach is beautiful in concept. #1 is where the MBR (GRUB) goes. #2 is where the UEFI bootloader goes. #3 is where the OS gets installed and mounted. My previous experience with Ubuntu was that it never wrote GRUB into any partition no matter how it was flagged. It always modified my WIndows bootloader and ignored the memory stick target when it came to installing Grub. Linux Mint 19.2 can do either legacy BIOS or UEFI but I have yet to find instructions saying how to force it one way or the other. All they say is that the installer will detect what you want if you partition it correctly. Well, it did. I now can get Linux Mint, and KDE Neon, to install GRUB onto that first partition which has a sole purpose in life to emulate an MBR. I've not mounted that partition to see what is really in there, but none of my computers will recognize it as bootable. This lead me to investigate the BIOS in my tower thinking something might be wrong there. Well the names of the hard drives are screwed up, but they all function as intended. Thus, what I currently have in my possession should work according to the LInux Mint tutorial you dug up for me.

It doesn't boot, and I have no idea why.

A NAND gate has at least two inputs to produce one output. It's the output that is the data bit so that I don't know how the term "pair" is derived. The idea is for that output to retain it's state, be it a one or a zero, after the power is removed. The inability of a gate to retain it's given state is what causes the failure. It's vague in my mind but I recall it has to do with capacitance and the charge retained therein. The capacitor effect diminishes over time just as those old fashioned electrolytics did. That's what distinguishes the good from the cheap flash drives. The method to hold that capacitve charge varies by manufacturer. Those which have it down pat charge you more for their devices.
User avatar
Kellemora
Guardian Angel
Guardian Angel
Posts: 7494
Joined: 16 Feb 2015, 17:54

Re: Way To Go - Finally

Post by Kellemora »

I know a very little bit about them, such as one voltage is used to set the data bit, and a slightly higher voltage is used to clear the data bit.
When I first read that a while back, it kept me from buying any USB sticks, because in my minds eye I figured all it took was one bit of static in your pocket to erase the darn things.

I know from audio and music reel to reel tapes, you cannot store them for very long because the magnetism will affect the adjacent turns of tape on the reel. This was even more pronounced on DAT's and they would lose data real fast.
The old 5-1/4 floppies were in jackets, and even if you kept them stacked up, they were far enough apart not to cause data loss on each other. I hated 3-1/2 floppies because they lost data sitting by themselves around nothing, hi hi.

I had a few SD cards from camera's and a voice recorder, I made the mistake of stacking them on top of each other on my desk. All it took was about three days and they were all messed up. So, I went back to keeping them in plastic cases, one to a case.

I do have a couple of USB sticks I carry in my pocket that I've had for years now, and they have never lost data.
Well, except for the two files I think the guy used a move command instead of a copy command.
I put them back and all is well.
I also have one here I use with the Printer to Scan images to the USB stick then copy them to the computer.
I learned it is not wise to reformat an entire USB stick, because there is some data on it that makes it work.
Only delete stuff, and/or format a partition you make on one, never the whole thing, else it won't work in another computer than the one you formatted it in.
Never mind, the part that makes it work is saved on ROM so you can't delete or format that area.
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

I must be very lucky with my USB usage because I can only recall losing one for all the years I've used them. The very first stick I bought is from Sony and unique in its styling. It has a capacity of 4GB total and I use it to carry around all my troubleshooting apps. I can't tell you how many times I've added, modified, and deleted programs from that stick and it's still going strong. It's at least 10 years old. I'm sure I paid through the teeth for it too because at the time it was a first for Sony to make such things.

During the course of my Linux On A Stick adventures I've been working more or less with four USB sticks. One of them is only 8GB and about as old as the Sony one. Each one of them have been totally reformatted, overhead files et al done away with. The 8GB stick must now number in the hundreds of times I've erased and installed a new OS onto it. The secret to success is to use the right partitioning program. Almost all of them will write those overhead files to the stick if they are missing. However, not all of them write the same files. That's part of the problem, but easily overcome by using mkusb in a Linux environment. If there are any bad gates on these four sticks, I can't detect them. They will probably all crash as soon as I finish sending this off to you, but as of this moment the memory sticks I've been using rival the hard drives they replaced. In fact the new USB 3 sticks are faster than most of the hard disks I have. LOL

We used magnetic tapes to back up the servers at Motorola. I think three years was all we kept them. Fortunately I don't recall ever having to do a recovery so that I don't know how well the data on those tapes was preserved. Presumably very well, but who knows?
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

Image
Post by pbear » Tue Feb 05, 2019 3:27 am
UEFI - Hybrid Install

This method is pretty cool, as it produces a USB drive which will boot in either BIOS or UEFI. It's the method I generally use because I have two laptops, one of each. Indeed, I’ve done it more times than I can count. Definitely works (so long as the computers involved don’t require special drivers). Credit to someone called msavini, who posted this to the Ubuntu Forum, where it was ignored and sank into obscurity.
The fdisk -l command will list all the file systems and partitions it can find.
I used that command to determine what was on the USB memory stick I recently created and will not perform a BIOS boot.

You will note up at the top that the file system type = GPT per instructions from the Linux Mint Tutorial.
Next is a table listing the four partitions on that USB stick:
  • BIOS
    UEFI (called Microsoft Basic Data)
    SWAP
    EXT4 filesystem
The rest of the image lists loops, which are not significant for this discussion. Everything looks as it should be but I don't really know what is inside that first BIOS partition. The way to find out is to mount it and have a look. The mount command is near the bottom of the image: sudo mount /dev/sdd1/ mount

To no surprise to me an error message was returned: The first part of the error is the most revealing where it states "mount /mnt: wrong fs type" The stated type is "BIOS boot" which is not recognized by GPT. My experience with this disc is that the Windows UEFI bootloader recognizes the /dev/sdd2 partition which is where the UEFI scripts will go but are not there yet.

This is terribly confusing, not to mention contradictory. The author of the article claims he has formatted and booted from MANY memory sticks using this method, yet I don't see how it is possible. GPT will not recognize a BIOS file system and vice versa. The disc format must be one or the other, not both.

I'd like to think I'm not being lied to here, but I don't see what I'm missing. :bleh:
User avatar
Kellemora
Guardian Angel
Guardian Angel
Posts: 7494
Joined: 16 Feb 2015, 17:54

Re: Way To Go - Finally

Post by Kellemora »

Maybe leave off the 1 on sdd1 and just mount sdd
Maybe a UEFI computer looks directly for the EFI table and not BIOS?

I have several LIVE CD and DVD OS's around here, and all but the Linux Mint 17 will boot on Debi's Win10 machine with only UEFI. Perhaps if I got a newer version of Linux Mint like 18 or 19 it would be compatible with UEFI.

I know this is redundant, but if a LIVE OS can boot up on any computer, I don't see what would stop it from booting up simply by adding a new Installed OS. I know you said it rewrites the MBR, but UEFI computers don't look at MBR do they?
Maybe this is why they Clone the Install from one USB stick to another?
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

I've about had it with Linux, and Linux MINT in particular. But, I'm a stubborn ol' coot and didn't run out of steam yet. But my patience is running thin. Anyway, to respond to your good suggestions:

The current release of Linux Mint is 19.2, Tina. This is not the same as Linux Mint 19.2, Tessa.
The difference is the desktop environment. Tessa = Cinnamon while Tina = Xfce
Isn't it lovely that they both have the same release numbers? NO IT"S NOT, but that's a different issue.

From what I can gather, the Linux Mint 19.x series is compatible with both UEFI and BIOS Legacy boot. Apparently the thing that determines which boot scenario will be used is the environment of the computer hardware, or more correctly firmware in what we are calling BIOS. If it's set up for UEFI, then Mint boots UEFI. If it's set up for BIOS Legacy then Mint boots into Legacy; so goes the theory and explicit instructions in the tutorials.

I did all the partitioning as instructed. It seemed reasonable and logical. The first partition /dev/sdd1 was unformatted and blank when I started, but now has a grub.img in it after going through the installation routine. Looks like BIOS, smells like BIOS, but I can't prove it is BIOS. That is why I decided to look at the actual files inside that BIOS partition to see what the heck they are and why they won't boot. How does one do such a thing? One mounts the partition using the command line editor. It's a trick I've used on other partitions that were UEFI. Should work on a BIOS partition too. Right? It turns out that the "mount" command is stupid. It knows nothing. It needs instructions from /etc/fstab (located in a different partition) in order to know exactly what file systems are available. Well, I'm trying to mount a partition that does not have an fstab file so that the "mount" command tries the obvious (whatever that is) and then gives up when it can't mount. That's where I'm at now. I can't mount the BIOS partition manually. When booting from a cold start, Mint tries to do what I'm trying to do and fails for the same reason. It can't mount the partition that (I think but can't prove) contains the BIOS Legacy boot scripts.

I did a lot of other things to try and boot, but can't come up with a solution on my own. So, reluctantly, I decided to go to the Linux Mint Installation Support forums and beg for help. Been there, done that, in the past. I have my login and password recorded in my secret file which is how I know I've asked for help in the past. Before I logged in, however, I did peruse a bunch of pages and topics that might relate to my dilemma. As usual, nobody is trying to do what I'm trying to do. They all are having problems dual booting next to Windows on a hard drive. USB is only used as an installation medium. But, the guy who wrote the tutorial appears in those forums so I figured I could ask a dumb question and he will enlighten me.

Now comes the part about why I hate Linux (lack of) Support Forums.

Entered my username and password and got an error telling me the username is wrong. They typically do that to make you log in twice as a verification that you are who you say you are. Not exactly 2-Factor authentication, but I've seen this trick in a few places. Well, after a half dozen attempts with the same error I clicked the link to contact an administrator if I continue to have problems. That link took me to a page wherein I can request a password reset. I don't want a password reset. I want a username. Unfortunately there is no option to query about a username. But I can now send an email to the Administrator to tell him about my troubles. The bottom line here is that the login to the forums for support is malfunctioning. It's broken just like the goddamned operating system they are pushing.

I admit that I know very little about Linux and even less about Mint. That's why I am using their tutorial. I don't know how to do it on my own. When the tutorial fails, well yeah, go to the support website. Well the login to the support site is broken. You know why this never happens in my experiences with Windows? Because it just works. Crappy as hell as Windows is, it works and can be fixed easily when it doesn't.

But you already know how I feel about that. I'll let you know if I find out anything relevant. But I doubt I will learn from the tutorials or the support forums designed to help guys like me.
:thundermad:
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

Oh, yeah, I was going to reply to your comments :mrgreen:
Post by Kellemora » Today, 10:56
Maybe leave off the 1 on sdd1 and just mount sdd
Maybe a UEFI computer looks directly for the EFI table and not BIOS?

I have several LIVE CD and DVD OS's around here, and all but the Linux Mint 17 will boot on Debi's Win10 machine with only UEFI. Perhaps if I got a newer version of Linux Mint like 18 or 19 it would be compatible with UEFI.

I know this is redundant, but if a LIVE OS can boot up on any computer, I don't see what would stop it from booting up simply by adding a new Installed OS. I know you said it rewrites the MBR, but UEFI computers don't look at MBR do they?
Maybe this is why they Clone the Install from one USB stick to anoth
Mounting the whole memory stick /dev/sdd is actually a good idea. I've not tried to mount multiple partitions all at once and don't really know if the "mount" command can handle that. I'll give it a shot later on. (UPDATE: I did try that. Same error)

UEFI firmware does not recognize legacy BIOS. That's why they invented it; to ignore BIOS and it's limitations. Thus, UEFI cannot see an MBR by definition. From what I understand that /dev/sdd1 simulates the MBR that UEFI cannot see. However, legacy BIOS computers can see it. I can't make my tower any more legacy than it is right now, and as explained in the above rant that is not the problem anyway.

Linux Mint 19.x will boot in the UEFI mode. I've done it, which is how I found out it will modify the Windows bootloader. I'm not sure about previous versions of Mint. Those might be all BIOS and not UEFI compatible.

Live CD/USB will boot anywhere because the UEFI and the old BIOS firmware are designed to prioritize booting of ISO images. The installed OS that results from using the live disc is not an ISO image. Thus it is subject to the relevant UEFI and/or BIOS boot requirement. Ubuntu, the foundation of Mint and other OS's, is flawed. That is not my opinion but a known fact. The Ubuntu installer that everybody and their brother uses to install their brainchild will not install GRUB onto the target disc. This is true even if you set the installer to do it. The flawed installer will install grub alongside the controlling bootloader, which in most computers is Windows on /sda, the first HDD. What I don't get is why they can't fix that problem. It's been around since forever.

You are partly correct about why it might be best to clone an OS to an already formatted and bootable disc. That eliminates the necessity for the built-in installer to do it. When I tried to "clone" an OS I could never do it and get the permissions copied correctly. That's why I abandoned the "clone" technique.

One obvious work around that I've seen posted in a few forums suggests to remove the HDD and do the Linux installation stand alone. If there is no HDD and Windows bootloader, it can't be modified. In theory that should work. All I need to do is remove the hard drive from my laptop every time I want to burn a USB memory stick. :rolleyes:
Last edited by yogi on 22 Sep 2019, 22:04, edited 2 times in total.
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

Image

I"m on a roll here, so you get three replies for the price of one. :mrgreen:

The above image shows the partitions on my ASUS tower hard drive (upper output) verses the partitions on the USB stick that will not boot (lower output). Both are BIOS/MBR bootable. Partition #6 of the hard drive has Linux Mint 19.2 Tessa installed. It boots as expected. Partition #5 of the USB stick has Linux Mint 19.2 Tina installed. It does not boot at all.

While the hard drive has an MBR, it's not shown in the partition tables output.
The USB stick has a BIOS partition to emulate the MBR and is located at partition #1.
Given that both devices have an MBR, why does the USB stick refuse to boot? I already speculated earlier it's due to the missing specs that are normally found in /etc/fstab, and that's the message I get when I try to mount bios_grub on the memory stick. More telling, however, is the Partition Table entry. The hard drive is msdos but the USB stick is gpt. I'm told that should not matter because UEFI (which needs gpt formatting) is backward compatible. Maybe so. But the hard drive boots and the stick does not.
User avatar
Kellemora
Guardian Angel
Guardian Angel
Posts: 7494
Joined: 16 Feb 2015, 17:54

Re: Way To Go - Finally

Post by Kellemora »

Just a thought, and I know it is a pain the backside, but one of the kids once said they have to unplug their internal HD, their main HD in order to install the OS on a flash drive from a flash drive.
Seems this was in one of the early instruction I've read also.
You have to have a LIVE USB Stick in order to boot up the computer.
Seems like doing it this way may prevent the install from writing to the internal HD, but may cause the install to fail also by my way of thinking.

You need a binary editor or hex editor to view the MBR.
Here's a site you might look into.
http://blog.hakzone.info/posts-and-arti ... -workshop/
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

That kid who disconnects the hard drive to install an OS on a stick is doing it the hard way. Yes that will work and people who think nothing of having a root canal also enjoy messing with the guts of their computers. It is an option and I will keep that one in mind, but there are other ways to accomplish the same thing. The idea is to isolate the USB stick so that there is no other controlling boot script available other than its own.

An alternative to physically removing the hard drive is to disable the UEFI boot partition. Without that partition being active Windows cannot boot. Nothing can boot. So ... if you happen to have access to Gparted on that host computer, you can set a flag to disable the UEFI partition. Then put in your live USB/DVD and install like a champion to any device you choose. When done, go back into Gparted and enable the UEFI partition again.

I may end up doing that, but there are even better ways to go about this whole process. That Linux Mint tutorial you provided lists them all. Getting any of them to work is the current challenge. I picked one method in particular that I like because not only is it simple, it also allows booting from both MBR and UEFI. That's the method I've been ranting about lately because I got half way through the process and hit a brick wall. As luck would have it, the wall is beginning to crumble.

To recap, the process of creating a hybrid boot USB OS on a stick begins with partitioning the memory device in a special way. It's not a complex way, but it is something I've not seen widely written about. If you can use Gparted, you can do the partitioning in less than three minutes. This specially partitioned stick is the target device upon which the OS of interest will be installed. So, you need a live DVD/USB to install it onto the formatted stick. Once that is done, you boot up that newly installed OS and proceed to install the UEFI bootloader from there. After that is done ... you are finished. I got all the way through the process but could not boot the newly installed OS on a stick. The requirement is to do that from the legacy MBR/BIOS mode because there is no UEFI capability until its bootloader is installed. Since I could not boot the stick on my MBR/BIOS tower, I went to the Mint Forums for help.

As luck would have it, the author of the tutorial and his buddy run that section of the support site. I had to re-join in order to post anything like a question and here is the link to my thread: https://forums.linuxmint.com/viewtopic. ... 6&t=302298 It might be too complicated for you to understand all the details, but the buddy of the tutorial's author knew the solution to my problem right away. It is a quirk in the BIOS of my tower. The GRUB used to boot into legacy BIOS resides in the first partition of that specially formatted stick. I could not boot from it or even mount it to see what's in there. He claimed the quirk is due to the partition not being active. Normally BIOS does not need an active partition to boot from, but mine is special. He explained how to make it active using fdisk, a Linux utility for partitioning disks. After some minor syntax errors, I accomplished the task and now my USB stick boots. Yay me!

This is only half the process. The next step is to install the UEFI bootloader and plug it into my Windows 10 computer to see if it actually works. It should in theory.



I don't need to edit the MBR, but I have been curious about what exactly is in there. I've run across methods of seeing it's content without using a hex editor, but as I said, I never really had a need to go into it. I have gone into the UEFI bootloader by simply mounting the partition. It's a little more complicated when it comes to MBR's. In any event, should I be successful creating the hybrid USB OS I'll have everything I always wanted. My expectations are high at the moment, but, unfortunatly, they are restricted to Linux Mint wherein the tutorial resides. None of this may apply to other distros, which would be typical of Linux.
User avatar
Kellemora
Guardian Angel
Guardian Angel
Posts: 7494
Joined: 16 Feb 2015, 17:54

Re: Way To Go - Finally

Post by Kellemora »

Well, I'm glad you finally learned all the little secrets, and especially why it was not working from the computer you were doing all the work on.

I was planning on going to the library today, however, a major upset here in my area has us all up in arms to the max.

I'll try to explain it as briefly as possible, but with a couple of important details.
Cities often have areas within the city limits that are called neighborhoods. Like Lafayette Square in St. Louis City, or Holly Hills, etc.
I live in the Plaza Park Community and to my north is the Southland Park Community. And way north of them, across two sets of train tracks is a Neighborhood called Vestal. It expanded slightly after a park was made to include the park. But still on the other side of the closer set of tracks.
In any case, in the early 1950s, Southland Park Community and Plaza Park Community joined to share a public park with both, and paid for by both, so they at first called it Southland and Plaza Parks Neighborhood. That lasted about a year and they dropped Southland and just called our area the Plaza Park Neighborhood.
Someone saw on Google Maps that they are calling OUR AREA Vestal, which is very degrading to us.
We found another map that showed us as Vestal, but the original Vestal Neighborhood was not included on that map.
A little more research and we found KGIS shows us and old Vestal all as Vestal now.
The term for this move is called Gentrification. And a way to increase our taxes by raising the Appraised value of our houses while at the same time causing the FMV Fair Market Value of our houses to drop considerably. The extra taxes go to improve the old lower Vestal Neighborhood and companies can get TIF and PILOT grants from the government paid for my our increase in taxes.
In a nutshell, it is almost like annexation, but they can't do that since we are inside the city limits now, so they just redraw where the recognized neighborhoods are and make it official somehow via their maps.
I've been up since 4 a.m. over this new issue and working with other neighbors who have been up just as early before they had to go to work. It appears there is not much we can do to buck against all the crooked poly-TICK-ians we have down here. Our taxes WILL go up to fuel new businesses and upgrades in the old Vestal Neighborhood, and there is little to nothing we can do about it.
Gentrification is akin to Blighting, but in a different way. They fix up the already blighted areas using our new tax money, while not doing anything except making all the rest of the newly acquired areas worse. Nasty to say the least.
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

WOW. I can't say that I'm surprised at your story regarding Gentrification. I'm also not sure how much of it is politics. The end results is more business and more money coming into the municipality which is messing with the boundaries. Unfortunately, some folks have to lose while others benefit. Overall the benefit is good for everybody, but I'd have a hard time convincing you of that if you can't pay the increased taxes. We left Illinois because we perceived the political environment as deteriorating and we could see a time when we would not be able to pay the taxes there. I think it's only a matter of time before we see something similar here in Missouri, but hopefully we will be dead by then.

The tutorial you found for me is excellent. The guy who wrote it is a genius. But, if you look at the link to my post in the Linux Mint forum you will see that yet another problem has occurred. The hybrid boot stick now boots on the MBR machine but not on the UEFI machine. It seems that the fix for the MBR disabled the UEFI. The guy who wrote the tutorial is stumped. He is looking into it because there is no obvious (to him) answer. The irony is that he claims he has a USB stick that can boot both ways. This guy is an expert in every way, but he is no better than the kids you are talking to at the library. I don't want to think it's a problem inherent with Linux. It just looks like it is at the moment.
User avatar
Kellemora
Guardian Angel
Guardian Angel
Posts: 7494
Joined: 16 Feb 2015, 17:54

Re: Way To Go - Finally

Post by Kellemora »

Well I have learned that USB Sticks with Linux installs will not boot up on small footprint Acer boxes which came with Win 8 or 10, or HP computer in monitor machines, or some Dell computers referred to as Dell Purple. They will only boot the OS supplied with the machine or upgrades of that OS without a new install. OEM licenses are locked to a specific motherboard too.
Apparently the Linux folks have figured a way to install Linux Distro's on those boxes but it requires some type of bios flash upgrade to do so.
I thought it was against the law to lock out other OS's, but apparently I'm wrong based on some other info I read recently.
Computers can be made to use the installed OS and nothing else, IF, they were designed for a specific market and usage.
They gave a couple of examples to show that although the computer is LIKE a desktop or portable computer, it was designed solely for a specific but complex purpose. One such computer, made by Dell, is basically a loading dock workstation. It can read a customer purchase order, check the inventory of the item, slate it for selection and packaging, even tell what size carton must be used for the order, determines the weight of the package with all items in the box. It also produces the UPS mailing label, and after the product is up for delivery, sends the filled purchase order back to the accounting department.
On inbound shipments, it compares the vendors packing sheet info with the inventory that arrived, a checksum so to speak, tells them what shelf it belongs on in the warehouse, and sends the update after all is checked off to accounting.
Machines like this do not have to comply with the ability to reload other OS's on the machine.
They also gave an example of an HP medical office system as well. The entire system is geared to all the separate medical office programs as a neat little package. Although it has an OS, it is not like a desktop OS and only used to drive the program package, so is still an OS, just not accessible by the users. They only see the log-in screen.
Sorta like the old Boot From ROM many games still use.

Speaking of weird things going on. We have DirecTV, a satellite TV system.
They came out and did a major upgrade last year and gave us a WiFi box.
Now this WiFi box not only connects the TV control boxes, but also connects to my Internet.
There are two lights on this box, one says Power, the other says WiFi.
The WiFi light can go out, and we will still get the TV shows, or most of them anyhow.
We can go to the other room and watch anything we recorded on that TV with the WiFi light out.
But then it gets weird. After a bit the TV will say lost communications, then resume the TV program.
Now even though the Boxes WiFi is out, and we loose access to some things on the TV, the RoKu dongle still works, so we know the WiFi itself is working.
I don't watch much TV but what we did learn is the reason it can record so many shows at once is because when we hit the record button, most of the recording of shows is coming over the Internet, not down the DirecTV satellite link.
Plus you cannot get to the advanced channel guide, only the one sent down via satellite.
However, there is a BONUS to this WiFi being connected to our Internet.
When you call service, instead of them coming out, they can upgrade the Black Box right from their office, and/or see what the problem is. So, instead of waiting three or four days for them to come out and fix something, they have it fixed often in under a minute, plus another minute to boot back up again.
Also, the frau found she can notify them via WiFi using the remote control without even calling them on the phone, which is also a hassle. Or she can go to her computer and log into her account and make it run a check of the system and see if the automated system can fix it. If not it flags a live person to take a look at it who is often also in a live chat box.

Oh, one last thing, even if they did have Fiber Optic run down our street, I found out the price to get on it, if I lived three blocks further east where it is already at. It is more than triple of what the average cost of Cable is. Ouch!



Or she
User avatar
yogi
Posts: 9978
Joined: 14 Feb 2015, 21:49

Re: Way To Go - Finally

Post by yogi »

Quite a few people around here have Dish and I honestly can't say how the price of it compares to underground cable. There is a fiber cable coming to our house from the distribution box out back of the lot. Then they have a 3-way splitter connected to the three outlets of our choice inside the house. When they built the house they put an outlet in every room so they all terminate at the junction box with the splitter. The video decoder boxes are at the end of two of those lines. The modem and phone are at the end of the third line in my office. Thus everything comes over one wire. Since I have a router for the computer network, any device that is WiFi can also connect to the Internet. All our mobile phones work off the WIFi in fact until they get out of range of the router. It's pretty simple and only $179 a month. Highway robbery is what it is. There is no way it costs anywhere near that much to give us the service, but it's their way or the highway.

You can look at the link to the Mint forum to see how this project developed. It was quite interesting to have two obviously knowledgeable people at my disposal. The goal was to make a USB memory stick with Linux on it and bootable in both the MBR tower and UEFI laptop. I originally was going to be happy with just the UEFI, but this one guy claimed he has a way to make the hybrid. The bottom line is it won't work on the computers I have. We can do one or the other, but not both. The experts don't know why that's the case because mine is the first firmware they've seen with that particular problem. So, I may have to abandon the hybrid concept, which would have been nice but not what I started out to do. I'll be trying to create a USB based OS that won't destroy my Windows bootloader next. The strategy is in the same tutorial as was the first method but not as elegant of a solution. I tried to do what they are saying is easy, but could not get it to work on my own. That's where your generous help came in handy. Anyway, they said they would help if I ran into trouble with the new method. We'll see how that pans out.
Post Reply