Adventures in Linux Land

Posted: 9/19/2019 4:53:43 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

Background & Motivation

I've been building PCs since the 286 days, and have been doing informal tech support for family and friends (and making a very minor amount of cash here and there - it's not a paid gig I actively pursue) ever since.  Assembling the hardware means you also get to install the OS, and I've done so many, many times: DOS, Win286 (!), Win386, Win3.1, Win98, WinNT 4.0, WinXP, Vista, Win7, and now Win10.  And replacing a bum hard drive or repairing the OS almost always means an OS re-install of one sort or another (especially for Vista and Win7, which can develop unsolvable networking and startup issues). 

For example, the very latest "fix" I did was for my young nephew's first laptop, a low-end fairly new but asthmatic HP laptop with Win10 (home).  With the stock 500GB hard drive, boot times were on the order of an essentially unusable 5 minutes or more!  I had a small 64GB SSD laying around, so I located the product key on the HD, swapped drives (getting inside laptops these days usually requires YouTube consultation), re-installed Win10, and voila!: a boot time of 12 seconds / shut-down time of 3 seconds, and no HP SW cruft.  Then I stuck WPS office and some other apps on there for him.

Several months ago I converted my wife's XP machine to Ubuntu 18.04.2 LTS.  The most challenging step was in converting her email from Outlook 2003 *.pst files to the mbox format used by Thunderbird: open all *.pst files in Outlook, close Outlook, download and install Thunderbird 17.0.9 ESR, allow it to import from Outlook (~1 hour process in this case), close and uninstall Thunderbird, download and install Thunderbird 38.5.0 (which pulls in the imported emails automatically), and then perform auto-updates to version 45.8.0, and finally 52.9.1, which is the last version to support XP.  Whew!

With the exception of one freeze and reboot, the installation of Ubuntu went pretty smoothly.  After that I migrated the email (much easier than an Outlook to Outlook migration) and stuck all of her files and such back.  It seems it's always the minor UI stuff in operating systems that drives you crazy.  I had to really mess with it to get a decent scroll bar width in Firefox.  Gnome for some reason sticks the system bar at the top of the screen rather than the bottom, which interferes with application window top bar behavior, so I installed "Dash to Panel" to move it to the bottom, and "Arc Menu" to bring back a more Win7 looking start panel.  *.url files are normally associated with URLs on Win machines, but not on Linux machines, so I had to install a different file manager (Thunar) and do some fancy scripting work to get those to work with Firefox.

Thinking Debian might be the way to go, as so many other Linux variants are based on it, I downloaded version 10.1.0 + Gnome + AMD64 + "live" + "non-free" (contains proprietary drivers) DVD image from their hidden "unofficial" page (!) and gave that a spin.  Got an error and had to log out, but it ran after that with wireless networking.  Again, system bar at the top - and the minimize and maximize buttons were missing from application windows!  Ye gods, what are these guys smoking?  Yes there are ways to change literally everything in Linux, and I can pick a different GUI at install, but sorry, no pure Debian for me.

I really want to leave the MSWin world altogether (a lack of functioning web browsers of all things is the main thing driving me off XP - currently using "Mypal" which is based on Pale Moon, it's the best of the worst), but the Linux UI world seems to drop the ball at every opportunity.  I'm sure there's a familiarity element at work in my head; and mobile screen resolution, form factor, and touchscreen input is playing strongly into it all; but most of the UI basics were discovered and hammered out at least decade ago.  I don't understand the need to constantly re-invent the wheel here, particularly when the results are demonstrably inferior to what came before.  Why are there a thousand different crappy windows managers in the Linux world?  I'm pretty sure there's no ergonomic science or engineering behind these seemingly random decisions.

Ah well, from all this I can recommend Ubuntu for those looking for a fairly painless install and OK default user experience.  Whatever you do, don't go to https://www.distrowatch.com/ and read any of the reviews of other versions of Linux - that way lies madness.

For applications, WPS office seems much more compatible with MS Office than Libre or Open office.  Though I can't find anything like TeraTerm (terminal emulator with scripting language) nor SyncBack (a simple HD sync / backup program).

[EDIT] I should mention that I've installed Ubuntu before on a laptop, as well as Pinguy and Mint on a couple of desktops.  For Mint, it took me forever to find a decent driver for the attached (fairly popular) printer, and even then printing wasn't the best.  Mint also got corrupted when someone accidentally pressed the reset button on the case, and I had to reinstall it to get it working again.  Getting the webcam to work in Mint was also a bit harrowing.

[EDIT2] Just did an install of "minimal" Ubuntu 18.04.2 LTS on my PC.  If you install WPS office, do it from the WPS web page and open to the installer, the versions in the native Ubuntu installer are weird.  Program install and uninstall is something Linux could use more work on, I had to manually uninstall the bum version of WPS from the command line.

Posted: 9/21/2019 8:23:07 AM
v7peer

Joined: 3/23/2014

I am also a linux user.  On my desktop I installed Debian 10 testing KDE Plasma I have used opensuse, ubuntu, kde neon, kubuntu, mint, manjaro as main os. Debian is not as easy as ubuntu but nowadays the difference between debian and ubuntu is not as large as it used to be. So I switched from kubuntu to debian and I have no regrets.

There are several backup programs in linux. I use Lucky Backup. Works good for me.
I do not know TeraTerm but there are plenty of terminal emulators available. So just google it
Linux has several editors that can be useful for scripting and/or programming . I use Kwrite (part of kde). I think that ubuntu has Gedit. But there are several other editors that contain tools for scripting and programming. A good example is Sublime Text.

Posted: 9/21/2019 9:03:32 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

Debian + KDE Live DVD Trial

Thanks v7peer!

I downloaded the Debian 10.1.0 +KDE +live *.iso file from their "hidden" site via torrent, ~1 hour download, burned it to DVD, booted.  It deposited me to the command line twice, threw out DVD.

I tried downloading the Debian 10.1.0 +KDE +live +nonfree *.iso file from their "hidden" site via direct download (no torrent file provided, unfortunately - but please don't burden our servers!) but it said it would take 7+ hours!  Tried with a different browser, it said 2 hours so I went with that.  Two hours later burned to DVD, booted.  It brought me to a desktop.  It saw my wireless, I entered the password, it tried to get me to save the password and when I cancelled that out the screen went blank.  Rebooting via reset button deposited me to the command line.  Powered cycled, selected the live session, went out for a run (it takes a while to boot off of DVD).  Came back to a lock screen wanting a password.  A blank password didn't work, neither did "pass" "password" etc.  Tried switching users and it deposited me to the command line.

I'm getting a certain vibe from this distribution, rather in line with my initial impression above.  For me it's been all uphill with Linux, which is why I tend to gravitate to the distros that concentrate on hand-holding (cuz there sure ain't enough of it going on).

I must say that Ubuntu is working so far, but it disconcertingly froze up for maybe 10 seconds once, about 1/3 of the time the shutdown doesn't want to complete, and the secondary drive in my system disappears now and then (and can't ever be seen by Quartus).

[EDIT] Finally booted into Debian KDE.  Had to really mess with it to finally connect to the internet (entered my passcode like 4x in various places before it finally took).  Billions of tweaks to the UI on tap but none seem all that useful?  I think I'll stick with Ubuntu for now.

Posted: 9/22/2019 5:30:45 AM
v7peer

Joined: 3/23/2014

Ubuntu is a very good linux os with a helpful forum. So stick with it.
 

Posted: 9/22/2019 2:39:18 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

Do It Slow, But Do It Now!

I held off forever thinking / hoping the stars would align on my transition from WinXP to Linux, and in retrospect that was a mistake.  It finally dawned on me that it doesn't have to happen in one fell swoop.

When the scheduled End of Support for XP happened on April 8, 2014, I thought that would push me over the edge.  But, other than several stern warnings from MS, that day came and went without event.  Over the years various SW providers dropped 32 bit support, and because of this I came to the conclusion that maybe 90% of anti-virus protection is just a game of scaring users into buying AV SW.  MS Office 2003 was showing it's age, but still worked fine for my needs (many MS Office updates seem to be largely UI / cosmetic, as underlying bugs remained unfixed) and there's almost no way in hell that I'm going to pay for subscription office SW.  But this is a PC used for development, and not being able to run the latest tooling on it becomes unacceptable at some point. (Though I will say that the FPGA tooling I use - Quartus - changes very little from version to version, compile times and top speeds in particular don't seem budge at all despite wild claims otherwise.)

I bought a couple of SSDs (Samsung 860, 256GB & 512GB) maybe a year ago and have had them sitting on my desk, staring at me since then - evidently insufficient motivation!

Weirdly, it's a lack of web browsers for XP that has become the hugest pain / largest motivator.  Chrome worked really, really well until they too dropped support.  Firefox dropped support, but has always been fairly sluggish on my PC.  I got by with a Russian Chrome fork (SRWare Iron) until embedded media stopped playing, then I moved to seamonkey, and finally mypal.  Even when an obscure browser works, there is usually a dearth of useful counter-measure plugins for it.  And mypal is really slow to fire up and open / close tabs.  The web environment has been changing much too fast IMO (and that change is directionally incorrect).

I found instructions on how to move email from Outlook 2003 to Thunderbird but sat on that because I thought transitioning email is something you wait to do until you're transitioning everything else.  But that isn't true, you can set up your email client to have your mail stay on the server for a couple of weeks - Indeed my wife and I already do this as it's a simple mechanism to share a single email account across multiple PCs / devices.

I don't know what finally prompted it, but three months ago I transitioned my wife's XP PC to Ubuntu.  Having a spare SSD and a USB backup drive takes all of the danger out of it: if the Linux install goes pear shaped you just stick the old XP drive back in there and try again another day.  You might be tempted to try a dual boot install (XP & Linux), but I would avoid that unless you're dealing with a laptop in which the drive is very difficult to get at, and even then I would avoid it as Linux installs can be rather cryptic / flaky, you don't want to erase anything on your XP drive, and unfortunately there is a very slim chance that you'll actually like and want to keep the particular blend of Linux that you've installed (a terrible state of affairs).

In conclusion: I was an idiot for putting it off, there are plenty of things to research and try and do while a candidate version of Linux sits on a separate SSD. Waiting for everything to somehow resolve and come together is waiting in vain.  When going through OS hell, find some way to keep going.

Posted: 9/23/2019 3:31:33 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

My Install Of Ubuntu Gnome 18.04.2 LTS

Here is where I am so far and I'm really liking it.  I haven't experienced a shutdown snag since I started closing all applications before doing the shutdown (duh!) and it all feels fairly solid.  Dash to Panel and Arc Menu are very well done and make the layout much more "Windowsy" - it's really too bad that they're not the default for Ubuntu desktop as they dramatically change the look & feel for the better IMO.

1. Install "minimal" from live DVD session, do updates during this (have wireless working in the live session).  Minimal seems to uninstall stuff at the end rather than avoid installing it in the first place (!).

2. Software Installer (just start typing once it's open to search):
- Gnome Tweaks
- Dash to Panel
- Arc Menu
- Clock Override
- Thunar
- VLC
- QMMP
- MediaInfo
- LuckyBackup

3. Tweaks:
- Appearance:
  - Applications | Adwaita
  - Cursor | DMZ-White
  - Icons | Ubuntu-mono-dark
- Background:
  - Image | noise-texture-light.png
- Extensions:
  - Clock Override settings | "%F    %l:%M %p"
  - Play with various options in Dash to Panel, Arc Menu

4. Disable Lock Screen:
- Click down arrow next to power button | tools button | Privacy | Screen Lock | Off

5. Turn off Automatic Updates Install:
- Software and Updates | Updates | When there are security updates: | Display immediately

6. Firefox:
- View menu bar & bookmarks toolbar.
- Import bookmarks from *.html file, then move them to the bookmarks toolbar.
- Add-ons:
  - uBlock Origin
  - New Tab Override
  - Open in Reader View
  - Activate Reader View

Fix too-thin vertical scroll bars in Firefox:
- File browser (CTRL-h to see hidden files):
- Create file: /home/.config/gtk-3.0/gtk.css
- Edit for following text inside:
.scrollbar.vertical slider,
scrollbar.vertical slider {
min-width: 10px;
}

7. Thunderbird:
- Install version 60.3.0 from SW installer.
- Copy XP version files over (takes a while), see help | troublshooting information | profies for location:
  mine is: /home/demo/snap/thunderbird/common/.thunderbird/fg7m4wzs.default
- Setup email account.
- If account is shared across multiple devices: Edit | Account Settings | Server Settings | uncheck "Until I delete them".
- Turn off junk mail filtering.

8. WPS Office:
- Install from web page, not from SW installer!: http://wps-community.org/download.html
- Download file to the installer.

I installed Quartus 18 and got it to compile the FPGA code, but the USB Blaster is really fighting me.  Spent most of yesterday working on it and got as far as programming the FPGA to program the Flash configurator, then it errors out - really frustrating.  Way too many layers of SW between the programmer and the the JTAG chain.  I'll give a more detailed report on this when / if I get it working.

Big thanks to v7peerLuckyBackup is exactly what I was looking for!

Posted: 9/23/2019 10:45:22 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

Quartus 18.1.1 Fully Functional

I just swapped out my cheeser USB Blaster for my genuine Altera USB Blaster and programming the FPGA suddenly works!  Milestone (feels like kidney stone) passed..

I did a billion things to get the cheeser to the halfway point, so who really knows what is really required for the genuine to work.

Quartus Install:
- Download 18.1.0 in parts (main & cyclone4), open containing folder.
- Right click & change permission of *.run file to enable execute.
- Double click to install, put icon on desktop!  This installs parts support from other files as well.
- Desktop icon command line is: /home/demo/intelFPGA_lite/18.1/quartus/bin/quartus --64bit
- Won't run, download to installer: https://packages.ubuntu.com/xenial/amd64/libpng12-0/download.
- Download update file QuartusSetup-18.1.1.646-linux.run, (5.4GB!), change permissions & run.

Here is some random flailing I did to try to get the cheeser to work:
- Selectable in Quartus but programming fails.
  - Unselect programmer, can't add back "insufficient permissions on some ports".
  - 209053 Unexpected error in JTAG server -- error code 89
  - 209012 Operation failed
- Console: "dmesg -w" then plug / unplug Blaster to see USB info, CTRL-C to quit.
- Temporarily add quartus/bin to console path: "export PATH=$PATH:/home/demo/intelFPGA_lite/18.1/quartus/bin"
- "echo $PATH" to check
- File browser, go to /etc/udev/rules.d/, CTRL-h to see hidden files.
- Create file "sudo touch 51-usbblaster.rules", "sudo chmod 666 51-usbblaster.rules")
- Edit for following text inside:
SUBSYSTEMS=="usb", ATTRS{idVendor}=="09fb", ATTRS{idProduct}=="6001", MODE="0666"
- Run "sudo udevadm control --reload-rules" to make the change take effect
- Console: "sudo service udev restart"
- Console: "jtagconfig" plug in Blaster, I got:
1) USB-Blaster variant [5-1]
  Unable to lock chain - Insufficient port permissions
- Console: "jtagd --foreground --debug", I got:
JTAG daemon started
Using config file /etc/jtagd/jtagd.conf
Remote JTAG permitted when password set
No USB device change detection because libudev.so.0 not found
^C
- Console: "tagconfig", I got:
1) USB-Blaster variant [5-1]
  Unable to lock chain - Insufficient port permissions
- Console: "jtagd --foreground --debug", I got:
JTAG daemon started
Using config file /etc/jtagd/jtagd.conf
Remote JTAG permitted when password set
No USB device change detection because libudev.so.0 not found
Can't bind to TCP port 1309 - exiting
- Console: "cd /lib/x86_64-linux-gnu/"
- Console: "sudo ln -s libudev.so.1 libudev.so.0"
- Console: "ls -la libudev.so*", I got:
lrwxrwxrwx 1 root root    12 Sep 22 14:32 libudev.so.0 -> libudev.so.1
lrwxrwxrwx 1 root root    16 Sep  4 23:59 libudev.so.1 -> libudev.so.1.6.9
-rw-r--r-- 1 root root 121016 Sep  4 23:59 libudev.so.1.6.9
- Console: "jtagd --foreground --debug", I got:
JTAG daemon started
Using config file /etc/jtagd/jtagd.conf
Remote JTAG permitted when password set
USB-Blaster "USB-Blaster(Altera)" firmware version 4.00
USB-Blaster endpoints out=02(64), in=81(64); urb size=1024
USB-Blaster added "USB-Blaster(Altera) [5-1]"
No permission to access /dev/parport0
No permission to access /dev/parport0
USB-Blaster port (/dev/bus/usb/005/008) opened
USB-Blaster "USB-Blaster(Altera)" firmware version 4.00
USB-Blaster endpoints out=02(64), in=81(64); urb size=1024
USB-Blaster port (/dev/bus/usb/005/008) opened
USB-Blaster "USB-Blaster(Altera)" firmware version 4.00
USB-Blaster endpoints out=02(64), in=81(64); urb size=1024
USB-Blaster closed

At some point I changed the USB port permissions to 666 (maybe "sudo chmod 666 /dev/bus/usb/005/008" ?).

Next up is getting the Hive sim/assembler compiled and running.

Posted: 9/24/2019 2:24:49 PM
v7peer

Joined: 3/23/2014

I cannot follow what you are doing (I am not a linux expert). But I see that you are working in directories that are owned by root. And this is dangerous.
You can use the sudo command to execute one command. When you want to execute a serie of commands it is better to change to the root account ("su -" in the terminal) or to login as root.

Perhaps changing the permissions for the usb port is ok but I do not think this is the normal way to do it. But i works.

Posted: 9/24/2019 3:52:58 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

Hi v7peer,

Thanks!  I'm acutely aware that I'm mucking around in the system and really hate doing it, though the Altera / Intel Quartus install guide itself says to add the file  /etc/udev/rules.d/51-usbblaster.rules.  The rest was from other guides on the web where folks seemed to know what they were doing, and were only in response to the various error messages thrown by jtagconfig and jtagd (missing library, insufficient port permissions, can't lock the chain, etc.).

I don't really understand why the cheeser Blaster doesn't work, as that type of interface is now added to the hardware on many demo boards.  I have to assume it's because the Linux version of Quartus doesn't get banged on as much, or perhaps most Linux users know enough to figure it out on their own?  I'm rather lost at sea and wish I'd tried the genuine USB Blaster earlier.

Thanks again for the LuckyBackup pointer!

Posted: 9/24/2019 10:58:11 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

Printer Installed

Unlike the MS Windows world, where at most you might have to install a printer driver, but very often all you have to do is plug the thing in, I've found Linux printer installation to be much more painful in comparison.  I plugged up my Samsung M2020 printer and Ubuntu found it, but it installed a text-only printer.  So I uninstalled it and followed some instructions involving the invoking of http://localhost:631/printers/Samsung_M2020_Series which brings up a web page of all things, but which ultimately failed to print the test page, so I uninstalled that.  Finally, I found and followed the following instructions, which worked:

Printer install (Samsung M2020):
- Plug in printer, connect USB, don't do auto install (this installs a text only driver).
- Go to: http://www.samsungdrivers.net/samsung-m2020-driver/
- Download driver: uld_v1.00.36_00.91.tar.gz
- Extract to Downloads dir, s/b "uld" dir with files in it.
- Console: navigate to ~Downloads/uld/, s/b "install-printer.sh" there.
- Console: sudo ./install-printer.sh
- Agreee to ULA, skip firewall config, done!
- Settings | Devices | Printers | Add a Printer... | M2020
- M2020 options (gear) | Printing Options | Advanced | Quality | High Resolution | x out
- M2020 options (gear) | Printing Options | Test Page

As I said, since I'm using this PC for development work, there are several make-or-break, go/no-go pieces that simply must work, or else I'll have to fall back to some variant of MS Windows.  Outlook mail migration was one, Word & Excel file manipulation was another, Quartus functioning was a third.  Not having my particular printer work as it should wouldn't necessarily be a no-go, but it would be a big mark against it.

You must be logged in to post a reply. Please log in or register for a new account.