Linux/Window split personality to boot! - Page 1
Forum section: electronics / general

author: PerranOak
author_rank: Frequent Contributor
timestamp: July 07, 2021, 06:42:21 pm
content: I want to have my old laptop dual boot Linux/Win8.1Pro.I want to investigate Linux and have a play but I also want to run MPLABX on it in the hope that it'll run faster without all the Windows "overheads"?Is there any particular distro that would be good for "playing" or that Imusthave in order to run MPLABX and obviate the need for raw computing power/memory?Also, what size of partition do I need? I can go up to 20Gb and that's it!Cheers.

author: StillTrying
author_rank: Super Contributor
timestamp: July 07, 2021, 07:01:23 pm
content: Most of them run from the CD/DVD rom, after eventually loading.I've got Linux Mint, even properly installed it's not faster than Win7 for some reason.A 20 GB partition would be enough.

author: Lindley
author_rank: Regular Contributor
timestamp: July 07, 2021, 07:38:28 pm
content: +1 for Linux Mint.If you dual boot, do take a full system image backup before doing so; eg Macrium Refelect FreeYou can install Linux onto a USB HDD rather than dual boot and just select which drive in the Bios Boot menu.

author: tunk
author_rank: Super Contributor
timestamp: July 07, 2021, 09:21:58 pm
content: Or you could run it as a virtual machine, e.g. using virtualbox.I.e. no (disastrous) problems with partitioning and you can run both in paralell.

author: RaymondMack
author_rank: Regular Contributor
timestamp: July 08, 2021, 05:27:25 am
content: It's always fun to play with a different OS. Linux has quite a few interesting differences with Windows. For one, you will become intimately familiar with the terminal. Most everything can be done using it with minimal effort. It also makes installing new software a snap, so long as you know what you are looking for.Here are a couple of thoughts about dual booting:Unlike Windows, you can install Linux on an external HDD/SSD. So you can boot from an external drive and leave your internal one alone if you are afraid of breaking a working setup.Fedora works flawlessly with secureboot, if you want to use that feature. I used Fedora on my Surface Pro 3 up until I sold it and was amazed at how much less memory Linux required than Windows 8/10.It's often easier to install Windows first, then Linux. Linux will list both itself and the Windows installation in the boot loader when installed second, while Windows will only list itself if installed second.Sometimes you need to enlarge the "EFI System Partition" to be able to properly dual boot. If you already have a working Windows install, this will likely require reformatting the drive since you need free spacedirectly afterthis partition to enlarge it. Usually 512MB to 1GB is plenty for the EFI System Partition (the Windows installer creates a ~100MB partition by default).I would recommend using a "live" USB drive or CD/DVD to test the OS directly on your HW. You can try it out in a virtual machine, but it's not the same thing as actually running directly on your HW. Will your wireless card / Bluetooth devices work? Or some other peripherals / misc. HW work? Can you get your printer to work? These are questions you need to answer before going through the effort of installing a new OS. Because they can be very, very annoying to deal with if you go in blind and find out you can't print or get on the internet. And not every flavor of Linux has the same HW support. Particularly with printers or very new HW.

author: newbrain
author_rank: Super Contributor
timestamp: July 08, 2021, 07:13:35 am
content: Quote from: RaymondMack on July 08, 2021, 05:27:25 amIt's always fun to play with a different OS. Windows has quite a few interesting differences with Linux. For one, you may, if you want, become intimately familiar with the terminal. Most everything can be done using it with minimal effort.Half-joking, but PowerShell gives complete access to Windows and its innards, very good advice for the rest.It's not mandatory - while in Linux it's a must*.Be very careful with Grub (Linux bootloader), it's the most obscure piece of software I ever encountered and hosed my installs a good number of times, I find BCD (Windows bootloader) easier - but (damn MS) they practically removed the possibility to boot non windows images without some tricks.If you just want to get acquainted with the command line, consider WSL/WSL2: no partitioning or need to select your environment at boot.99% of the command line SW works, and if you code you can have your build environment in WSL and access through VS Code in Windows, the major drawback is that no USB (or other devices) passthrough is supported (only USB serial ports on WSL1 - none in WSL2).While we wait for WSLg (I tried it in an insider build, works very good for a preview product), graphics application can be run using an X server in Windows.*Last personal example: To avoid the mouse waking up my media player (Ubuntu on a NUC) I needed some command line magical incantation and startup file editing - providing a tick in the mouse properties was apparently too complicated or too much effort.

author: tszaboo
author_rank: Super Contributor
timestamp: July 08, 2021, 07:28:49 am
content: I did double booting, maybe 15 years ago. It is always PITA to handle a computer like that. The rule was to install windows first, linux second. I don't recommend doing it, I honestly don't see the benefit over virtualization. You install the host OS which absolutely needs to have access to Hardware, for me thats Windows every time, because passthrough video card is not always reliable. And use Linux in a virtual enviroment.If you only need mplab on windows, your order is of course Linux first.

author: Zero999
author_rank: Super Contributor
timestamp: July 08, 2021, 07:35:14 am
content: Quote from: RaymondMack on July 08, 2021, 05:27:25 amThat made be laugh because I've used Linux for 6 years now, as my main operating system and am still unfamiliar with the terminal. Modern desktop distributions can be driven with the GUI 99% of the time. If you like to use the command line, or are interested in learning it, then good, otherwise it's largely optional nowadays, just like with Windows.

author: RoGeorge
author_rank: Super Contributor
timestamp: July 08, 2021, 08:05:51 am
content: If you are new to Linux and want to learn more, the best way would be to install Linux as avirtual machine.A virtual machine is like a program, or an app. It simply starts and run from your current Windows. It's like you would have a second laptop inside your current OS (Operating System - yours is now Windows). It will have everything, including a separate BIOS and boot, etc.By using a virtual machine you can:- create as many new "laptops" as you want- install in each new machine whatever OS or programs you want- never need to reboot to switch from Windows to Linux- always have the OS you are the most familiar with (Windows) up and running- you can copy files or copy/paste text between Linux and Windows by simply drag&drop or copy/paste- you can save the state of a virtual machine, or you can clone one entirely (for example you want to experiment on the virtual machine with something that can damage it - make a snapshot of the VM (Virtual Machine) then you can even format its disk and it doesn't matter, you can revert to the previous working state)- you can pass physical devices, for example you can try to use your favorite PIC devboard, but with Linux - plug the USB, then give the detected devboard to Linux for usage - and the devboard will disappear from the Windows USB and reappear in the Linux machine's USB- you can allocate the amount of RAM or to cap the maximum disk size, etc.- once a virtual machine running, you can preserve it and it will still run no matter haow many upgrades will break your current installs, for example you can use a new VM to install another windows+mplabx, then disconnect the VM from internet to be sure next windows update won't break your mplabx or devboard drivers)- once you create a VM and install an OS, it's like a file. You can copy it on a USB stick, go to a friend that only has a MAC, and run your Linux VM on that MAC. VMs can be run on any OS and on any VM player- all you need is a few GB of free disk, and not all at onec. For example, if you create a new VM with 100GB of disk, but you only use 10GB of them to install Linux, then the VM will only be a 10 GB file, not 100GB. 100 is only the max allowed (and Linux will report 90 GB free, though the 90 GB are not taken from Windows in advance)There are many other advantages. Use Virtual Machines. There is no visible speed penalties, it will run just like a dual boot install, except you don't need to reboot and you can have as many OS's as you want without messing with the current install and without the need to repartition your disk.It's free software. Install on your current windows either VirtualBox or VMware Player. I like VirtualBox more, but it's up to you.Once you get used with VM you'll used VM all the times. I have tenths of them. For the most common OS's you don't even need to take the time to install the OS, there are preinstalled VMs to download and just run with whatever VM player you like.Dual boot is a thing of the past. You won't see any advantages or any extra speed from dual, only the risk of damaging the current install and the limitation of only trying a single type of Linux at once. With VM you can run side by side 3 flavors of linux an WinXP and a Win10, if you want.Use Virtual Machines. Just download and install VirtualBox or VMware player. No need to mess with your current OS, with the boot, or with the disk partitions. If you don't like a VM, just delete it. If you don't like VirtualBox or VMware player, just uninstall them. They don't mess with your current disk or with the current Windows.Use Virtual Machines.

author: newbrain
author_rank: Super Contributor
timestamp: July 08, 2021, 10:00:06 am
content: Quote from: Zero999 on July 08, 2021, 07:35:14 amLargely - but not enough, see my example above (and below).It's a seldom occurrence when anything can be fully accomplished without some CLI interaction.This is not to disparage Linux, Ilikeusing CLI.Today's example: I'm using Mint on an antique laptop*, and I had to install nVidia proprietary drivers; for some reason the FOSS ones had problems coming out of sleep, giving me a multicoloured "snow crash" 50% of the times.While the driver itself installed with just a couple of clicks, to have it start automatically at boot I needed to manually add the nvidia module to /etc/modules.It's a minor thing, and it's most probably nVidia's fault, but still...*BTW: it dual boots with Windows 10, it's not any faster in Mint, but the memory pressure (it only has 4GBof RAM) seems much better for my use (VS Code and Firefox, mostly).

author: Zero999
author_rank: Super Contributor
timestamp: July 08, 2021, 01:45:36 pm
content: Quote from: newbrain on July 08, 2021, 10:00:06 amI couldn't dissagree more about needing to learn how to use the command line. The odd occasion, where it's needed, I just Google it and copy/paste, without bothering to try to understand what it means. I just need it to work. Monkey see, monkey do.I don't mind command line user interfaces, but find the UNIX shell inherently unintuitive, so I decided to avoid it, where possible and have little interest in learning it. Fortunately that's not stopped be from using Linux.

author: esepecesito
author_rank: Regular Contributor
timestamp: July 08, 2021, 02:02:23 pm
content: Quote from: PerranOak on July 07, 2021, 06:42:21 pm20G is plenty. My recommendation is to take any distro not using the systemd rubbish. Here a list of no-systemd distroshttps://nosystemd.org

author: newbrain
author_rank: Super Contributor
timestamp: July 08, 2021, 05:51:10 pm
content: Quote from: Zero999 on July 08, 2021, 01:45:36 pmI wouldn't know - it's a strategy that almost never worked quite right for me, but YMMV.In any case I was making a slightly different point:In Linux you stillneedthe command line for a larger quota of day-to-day stuff, in much greater proportion than with Windows (or macOS).Do it blindly or knowingly, but it's something that's difficult to escape.I just happen to not being averse to it, and prefer to understand what I am doing when my command line starts with sudo (or when I get an elevation prompt from Windows)That said, only a minority of my physical PCs is natively Linux or freeBSD, I mostly use VMs so it's somewhat easier going straight for a shell than bringing up a remote desktop.Quote from: esepecesito on July 08, 2021, 02:02:23 pmWhile I do not like systemd very much myself, I would advise a Linux novice to use a well supported distribution with a wide community.Once they are well acquainted with the OS, they can make up their own mind and move to more niche distro.Linux Mint (already mentioned a number of times in the thread) is a least surprise distro for someone coming from Windows.

author: Zero999
author_rank: Super Contributor
timestamp: July 09, 2021, 07:45:13 am
content: Quote from: newbrain on July 08, 2021, 05:51:10 pmI can probably count on one hand, the amount of times I've had to use the command line, on my home linux computer, in the last 6 years. In fact, I can't even remember the last time. I thin I used the command line more often, when I ran Windows, but admittedly, it was probably because I'm more familiar with it.

author: esepecesito
author_rank: Regular Contributor
timestamp: July 09, 2021, 11:25:39 am
content: Quote from: Zero999 on July 09, 2021, 07:45:13 amQuote from: newbrain on July 08, 2021, 05:51:10 pmIt all depends... if you want to LEARN Linux, then maybe better to go for a "complicated" distro. Look the quote from Zero999... you can get away with just "using" linux without really learning all you can do. That is what I do not like from the "well supported" distros. I've know people at work who have "10 years linux experience" and literally do not even know that there is a "grep" command.I think the original question was more in the sense "I just want to run an app on it" so, I guess in that context, you are righter than I am

author: janoc
author_rank: Super Contributor
timestamp: July 09, 2021, 11:45:27 am
content: Just a note to the OP - if you are after the ultimate performance,do not runLinux from a USB drive (especially not a USB stick), live CD/DVD or even in a VM.There is always some performance penalty involved if you do so, either because of the slow external storage or having to pass through to hardware through some virtualization layer.Use a VM to test whether the distro in question works for you and does what you need and then install it to a dedicated partition or (safer) disk and dual boot.Obviously, if the VM performance is fine for you, there is no need to dual boot. I am mentioning it because people do all sort of crazy things (like running Linux inside Windows using FAT filesystem - there used to be a setup like that) and then complain that "Linux sucks!" because it is too slow, some hardware doesn't work, graphics is limited and what not.Quote from: esepecesito on July 09, 2021, 11:25:39 amSorry but that is really a terrible advice to give to a newbie who has never used Linux before, has no idea what systemd is (and that unless they are into the anti-systemd religion already it is most likely completely irrelevant for them) and has no means to debug the inevitable problems. Compounded with the fact that an obscure distro with few users will not have extensive support and documentation available neither.Sure, you can teach people to swim by dropping them in the middle of a deep lake and possibly some will manage to swim ashore. But the majority will drown, or in this case, throw hands up in despair and go back to Windows because with that they were at least able to get some work done.I remember how people were recommending Gentoo to newbies when Gentoo and building everything from source spending days compiling was the hottest fad du jour. It has put a lot of otherwise very skilled people off because they thought that Gentoo is what Linux is like (the rather vocal and often toxic & immature community around it didn't help neither).And I really wonder why knowing the grep command is any measure of skill or experience. I guess those colleagues of yours didn't need it during those 10 years? Did they get the job done? If yes, then what is the problem? I suppose that their job description is not learning grep (or how to use command line in general) but getting whatever work they are doing done, no? Dial back that elitism a little, shall we? Linux is atool, first and foremost. The same as a screwdriver or soldering iron. Not a religion.

author: Zero999
author_rank: Super Contributor
timestamp: July 09, 2021, 12:42:50 pm
content: Quote from: esepecesito on July 09, 2021, 11:25:39 amWho cares? Many consider learning to use a new command line interface to be a waste of their time. They just want to get their work done. For those who want to learn something new, then great, otherwise why force them?

author: StillTrying
author_rank: Super Contributor
timestamp: July 09, 2021, 02:34:44 pm
content: I'm quite used to using the CLI, hardly an expert, but I found the Toys Я Us Mint useless. Even when I had linux drivers on a CD often clicking on a .sh file nothing happened not even a message or error message, so I gave up after a few hours.

author: esepecesito
author_rank: Regular Contributor
timestamp: July 09, 2021, 02:57:39 pm
content: Quote from: Zero999 on July 09, 2021, 12:42:50 pmQuote from: janoc on July 09, 2021, 11:45:27 amYou are absolutely right! 100%, if you think an operating system is just a kind of "necessary evil" to run an application. Specially this was the context of the original question. So YES. you are right.Just as a side note, if somebody wants to know what Linux (or better Unix "philosophy") is about, and wants to learn about it, is a different story. It comes from the time where the operating system was part of the system. You could do 90% of what the computer could do with just the operating system -- I've seen complete industrial plants run in plain Solaris, just a few scripts written in the command line. Getting a job done with a tool, and knowing how to use a tool, are two very different things. As you say, it is a tool, but what happens if you see somebody in a workshop doing holes with the soldering Iron? Or using any tool in the 1% of what he?/she can do with it? wouldn't you try to help, and teach all that can be done, out of friendship? Nothing to do with elitism. And depending on which industry you are, believe me, command line is very important. Just ask a database administrator of a bank, for example.But I digress, and foremost, you are absolutely right in the context of the question.

author: PerranOak
author_rank: Frequent Contributor
timestamp: July 11, 2021, 01:21:27 pm
content: Right. Brilliant. Thanks all.So, I now have two objectives:1. find out about VMs (I love the idea of it!) and how it all works and from within this "play" with Linux in more depth. (I'm guessing that: Linux + VM + v.old laptop = not a performance enhancing move)2. use Linux to get my old laptop to run MPLABX more quickly.I'll put the VM stuff in another, future, post.So, will installing Linux on a dedicated partition on my old laptop give me MPLABX with enhanced speed over my current situation?(Current situation: MPLABX on Win8.1 Pro, 32 bit, Acer Aspire 5610Z, Intel T2060 @ 1.6GHz, 2Gb RAM{can't increase RAM})

author: StillTrying
author_rank: Super Contributor
timestamp: July 11, 2021, 06:49:20 pm
content: Quote from: PerranOak on July 11, 2021, 01:21:27 pmI don't think you'd gain anything on a 32 bit CPU, the latest Mint is 64 bit only AFAIK, I don't know about any of the others.Before you do anything do you have another online PC, laptop or windoze notebook, because it might be a while before you get the laptop working again.I'd be surprised if there's any way for you to beat Win8.1.

author: RaymondMack
author_rank: Regular Contributor
timestamp: July 11, 2021, 08:40:41 pm
content: Quote from: StillTrying on July 11, 2021, 06:49:20 pmLinux will use less RAM than Win8.1, which, in the OP's case,willspeed things up since he or she won't be as reliant on page file. I assume the laptop has a HDD rather than an SSD. With that little memory, an SSD would have seen excessive writes and likely be at its TBW endurance limit. This was my biggest complaint about my Surface Pro 3--which only had 4GB of RAM. Just opening up a modern browser caused it to immediately use page file. Palemoon helped, but it wasn't a cure. Linux made running Firefox possible, but again, Palemoon was still the better choice.I like Fedora, but Mint is okay. Memory requirements on Linux can be further reduced by choosing the appropriate desktop environment. With how little memory you have, I would absolutely not test out the OS in a virtual machine. You simply have too little memory to spare. Use a live USB drive and test that way.The OP's machine sounds like it should be running Win7 or XP to be honest, not Win8.1. Just because you can use a newer OS doesn't mean you should. You can make your own up-to-date ISO for Win7 if you go to the MyDigitalLife forums and use one of the projects provided by the forum members to integrate all the updates. This is also true of Win8.1 and 10, if anyone hates installing updatesafterreinstalling Windows. It's a great resource for anyone who has to regularly deal with Windows installations.

author: PerranOak
author_rank: Frequent Contributor
timestamp: July 12, 2021, 02:54:09 pm
content: Cheers.In reality it looks like I'll get nowhere trying to force a little more speed out of my old machine.I'll just have to lump it until I can get a new laptop past "She Who Must Be Obeyed"!

author: Lindley
author_rank: Regular Contributor
timestamp: July 12, 2021, 05:06:46 pm
content: Have you already done or considered any of the following to speed up Windows and the Laptop ?Clean install, extra ram, SSD if motherboard suitable, faster CPU if you can find a s/h one ?Depending on the work and chips you are using, would the old IDE MPLab 8.92 be faster ? ( assume it the compile time thats frustrating you ?)

author: PerranOak
author_rank: Frequent Contributor
timestamp: July 13, 2021, 10:12:05 am
content: Cheers. It is a newish install and the machine can’t have anymore RAM. Stupidly, I always update software to latest possible versions. I also change my code to match!