Thursday, December 14, 2017

Allow http through firewall on CentOS 7

$ firewall-cmd --permanent --zone=public --add-service=http
$ firewall-cmd --reload

Missing ifconfig on recent Fedora-based distributions (RHEL, CentOS, Scientific Linux)

In the absence of ifconfig, use the following to reveal your IP address:
$ ip addr

Thursday, December 07, 2017

RHEL yum update

If you know your way around CentOS or Fedora and find yourself in front of a new RHEL system, you might find you're unable to run yum update or yum install due to subscription errors.

You need a redhat.com account for this to work, simply issue:
$ sudo subscription-manager register
Follow the prompts and then:
$ sudo subscription-manager attach

You'll then be able to yum update to your heart's content.

Thursday, November 02, 2017

youtube-dl - 'list' is not recognized as an internal or external command, operable program or batch file.

Struggled for a while with youtube-dl trying to retrieve a playlist and converting to mp3 with this pilfered syntax:

youtube-dl -i --extract-audio --audio-format mp3 -o "%(title)s.%(ext)s" youtubeurlhere

Kept getting pesky error in the subject - just put the URL in double quotes ("youtubeurlhere").


-i parameter allows retrieval of media to continue in the event of error ("not allowed in your country", etc).

Copying ffmpeg bin's and youtube-dl.exe to %Windows%\System32 as well as the working folder seemed to help.

Source

Friday, October 27, 2017

Ubuntu Grant Sudo Access

I created a new Ubuntu user for a colleague using command "adduser username", but noted that the new user doesn't get sudo permissions by default (sensibly enough).  Easily rectified:

$ sudo usermod -a -G sudo username

Obviously in both cases replace "username" with the actual user's login.  The new user needs to log off and back on for the change to take effect (tested to confirm).

Ubuntu 17.10 Configure Static IP Address Command Line

Having promised a colleague that I would set up a Linux VM for him to play around on, I decided to use Ubuntu Linux 17.10 Server - he's interested in encryption and security so a desktop environment wouldn't be of much value.  The installation was typically Ubuntu smooth, but I was surprised to see that /etc/network/interfaces contained no reference to my active NIC, ens160 on my system - I still miss eth0 :(.

Seeing as Ubuntu 17.10 is quite new at this point in time, there wasn't a great deal of info as to how to statically configure the LAN adapter(s).  So without going into too much detail, you now need to know about netplan in order to configure Ubuntu NIC's.  My understanding is that this provides a more platform agnostic platform for LAN configuration, in order to provide a more consistent method across local, VM and cloud deployments.

Anyways, here it is - you want to edit /etc/netplan/01-netcfg.yaml.  Mine started out looking like this (DHCP auto config for LAN adapter ens160 - note that your LAN adapter might be called something else):

# This file describes the network interfaces available on your system
# For more information, see netplan(5).
network:
  version: 2
  renderer: networkd
  ethernets:
    ens160:
      dhcp4: yes

I had to revise it as follows:

# This file describes the network interfaces available on your system
# For more information, see netplan(5).
network:
  version: 2
  renderer: networkd
  ethernets:
    ens160:
      dhcp4: no
      dhcp6: no
      addresses: [192.168.0.10/24]
      gateway4: 192.168.0.1
      nameservers:
        addresses: [8.8.8.8,8.8.4.4]

Save changes and execute "sudo netplan generate", followed by "sudo netplan apply".  Obviously if you're remotely connected you then want to connect to the new IP.  Credit to user Rolf over at askubuntu for helping to shed light on this.

Thursday, October 26, 2017

Owner's Review 2014 BMW F30 320i

I've had my 2014 BMW F30 320i for just under a year now, and thought I would share my thoughts on this vehicle.  When the F30 first came on the market to replace the good looking (pre-facelift) E90 in 2012, I wasn't entirely sold on the looks, but it's grown on me.  I'm still not crazy about the headlights stretching to the grille in front, but have gotten used to it and it looks to be part of BMW's design language which will be with us for a while.

I purchased the 320i to replace my beloved 2012 Suzuki Swift 1.4 GLS hatchback, when I needed a bit more space to accommodate my recently arrived son and associated paraphernalia.  This is my second BMW, the first was a 1999 E39 528i which I drove for about five years.  I must admit that I didn't quite get the same fantastic impression driving the F30 for the first time as I did driving the E39, but it is possible that I've become a little spoiled over the years (I moved up to the E39 from a battered 1985 Mercedes W123 230E).

To help set the scene here, I live in South Africa where cars are generally more expensive than the rest of the world.  Our economy is also not that great right now, so for me buying a car is something which I put a lot of thought and research into.  It's always amusing to chat with people from other countries, who smugly enumerate their long lists of option packs and track packs and this packs and that packs.  Whilst I'd certainly like some of those additional luxuries, they are just that and it can be difficult to justify the additional expense.  More on which options I would have liked below, though.

I chose a secondhand silver model in very good condition and with low mileage (about 35,000km's when I took ownership).  I would have liked the M Sport edition, but couldn't quite justify the price premium.  I also think that the F30 is one of those models where the front bumper of the non-sport model is almost as attractive as the gaping maw of the M Sport.  Mine came with 17" rims, which also means cheaper tires than the 18/19's on the Sport when replacement time comes, but still more presence than the unattractive 16's on lowlier models.

One inclusion which I was very pleased with was the xenon headlights with white "angel eyes" - it's pure vanity, but I always wished for these on my E39.  I could do without the pesky headlight washing system, though - this just squirts water everywhere and means you have to more frequently fill the window washer reservoir.  Other handy inclusions were PDC sensors front and rear, auto headlights and auto windscreen washers - I've gotten very used to these features, which I believe are standard spec.

I bought the vehicle from a private seller, but ended up collecting it from a dealership where it had had its mandatory inspection for the Motorplan to be transferred to my name - R1500 well spent for three years of peace of mind.  It was both thrilling and daunting to drive it home, being the most expensive car I'd ever driven.  Once the initial thrill had worn off, I did notice a few niggles.  I'm quite large (yes yes, working on it), and the standard seats feel very narrow - it feels as if the non-adjustable bolsters are almost in the middle of my back.

The front seat belt clips are also set quite low, and it can take a little bit of fiddling to get used to their placement - I now pass the belt from right hand to left, which seems to make it easier (right-hand drive in SA).  It also took me quite long to find a comfortable driving position with the manual seats - on longer trips I would quite often get cramps in my legs.  I now find the car quite comfortable, but it took a while to get used to it - I initially almost regretted my decision.

I was a big fan of the BMW straight six in the E39 and wasn't expecting the same silky character from the F30's turbo four, but I must say it has its own charm.  It has a pleasing rumble when pottering around town - it is distant and muted, but present nonetheless.  Open the taps and acceleration is smooth and linear - it feels very fast off the line, which the ~7.5s 0 to 100 time attests to.  Get the revs just right and there is a distant choof from the turbo when shifting.  I would love a little bit more audible feedback from the engine and exhaust - maybe the Sport would have brought that.

Speaking of the Sport, there is a surprising amount of body roll on my vehicle, most notable when going around traffic circles/roundabouts.  It sticks and sticks and I haven't yet come close to losing traction, but it is less than re-assuring when it feels as if you're leaning like a yacht in a gale whilst cornering.  I've read that this can be addressed with the adjustable suspension option, I'll probably seriously consider inclusion of that option if/when I buy BMW again.  Performance on the freeway is just about spot on - BMW's driving pleasure adage definitely applies there.  Steering feel and response is great too, nothing more to be said there.  The steering wheel itself is also fine and feels good, although the tiller included with the M Sport is much smarter looking (the proper one, not the normal 3-spoke with M badge).

Compared to other modern the cars, where there has been so much development in this area lately, the infotainment system on the base model feels a bit antiquated.  There's USB and aux support, decent Bluetooth phone connectivity but no Bluetooth audio streaming - really BMW???  I get by using a little Bluetooth dongle in the aux port and permanently charging off USB to get my Google Music groove on.  This is a pest as I have to switch it on every time I start the car (seems to the case with most of these dongles) - in fact it might be easier just plugging in the aux cable every time.  I'm not fussed about the lack of satnav, I prefer using my phone anyway.

The iDrive interface is perfectly usable for the minimal functions exposed in my model (basically radio and telephone).  I'm also not concern about the lack of touchscreen, I prefer the main controls being via tactile buttons I just have to glance at when on the move.  The sound from the base stereo is adequate and seems to be getting better with time, but the upgraded HK head unit would be a very tempting selection if I had that options list in front of me.  In terms of general features, I thought I would miss the comfort access option from my Suzuki more than what I actually do - pressing a button on the key fob or on the door to unlock is about the same amount of effort.  I do appreciate the start button - hop in and go - the physical key on a Ford Focus I recently tested seemed a bit archaic.

Considering that my daily commute is a very short stop/start trip, my fuel consumption figure of 11.6 l/100km is to be expected - it gets better on the open road.  I ruled out a diesel and the associated consumption benefits from the outset, because apparently daily short trips and diesels aren't a good mix.  Also they belong in tractors.  One aspect of the F30 which surprised me is its size - this is quite a big car, only a little smaller than my old E39.  It's not obvious when you look at it, but is when you're driving it.

Visibility is generally good, but I find it to be a hassle to park.  There is very little sense of where the car's corners are, and even parking in a normal horizontal bay can take a number of attempts.  I was pleased to see that it wasn't just me that encountered this difficulty when I raised the topic on an online forum - the current gen X3 also received the same complaint.  I'm getting used to it, but I don't recall ever having this difficulty with the E39.  Ironically two of the stereotypical BMW attributes - bad parking and imrproper use of turn signals - both seem to be encouraged in this car.  The turn signals aren't that great, they feel solid but often stay on when I don't want them to, or go off when I want them to stay on.

Minor niggles aside, I'm not at all sorry I bought the 320i.  I get a thrill every time I see it, and always look forward to going for a drive.  I might consider something a little more compact next time for that nippy feeling I miss from the Suzuki, but otherwise give the F30 a solid 4.5 out of  5.

Wednesday, October 25, 2017

GNS3 on VMWare ESXi - Useful Links

After getting GNS3 up and running under ESXi, I found these links useful:
GNS3 Latest Version
Be sure to use the GNS3 frontend version which corresponds with your server version.  When installing the frontend on your client PC, you only have to select GNS3, nothing else (dynamips, etc.).  Be sure to update after updating server version as well.
Installation
Very straightforward, follow the doc and it should work - do note the ESXi 6.5 caveats/required updates.
IOS images
If you must
Appliances
Lots of cool stuff here, the appliance file will usually guide you to any additional image files which need to be downloaded and can then be imported via GNS3 frontend
IOU images
I don't know about the legality of this, but we're all using the product for educational purposes and to better ourselves - I don't yet know of another way of getting the required IOU images.
Generate IOU license
Note that the http://gns3host:8000/upload method is no longer used, configure your IOU settings and license via GNS3 frontend: Edit -> Preferences... -> IOS on UNIX.  Run linked script on GNS3 server host and look for iourc.txt output file in /home/gns3 if using default user settings.  Upload that file and note other instructions output by script.

Monday, October 23, 2017

Remix Mini - Buyer Beware / Lollipop Forever

I recently purchased a Remix Mini compact Android PC, for the purposes of getting Netflix, Kodi and YouTube to my old non-smart Samsung plasma TV.  I was previously using a clunky old Dell 780 minitower PC which served the purpose well, but took up a lot of space.  The Remix Mini gets a lot of positive publicity, with most reviewers being of the opinion that if you have realistic expectations of the performance from such a small and cheap unit, you won't be disappointed.

Armed with that knowledge and having gotten one for a bargain basement price, I was pleasantly surprised by the performance of the little box - it's no rocket, but works amply well for my purposes (mostly - more to follow).  I wasn't fussed with the maximum 1080P output, even when I subsequently upgraded to a Hisense M7000 4K smart TV, 1080P looked fine from couch distance.  Apparently the Remix Mini is the result of a successful Kickstarter campaign and seems to be a bit of a media darling in that respect.  I did note that once it had loaded its initial updates, it was still on Android 5.1 / Lollipop.

I didn't think much of this at the time, assuming that the unit would still be well supported and would eventually upgrade itself to Marshmallow.  Alas, 'twas not to be.  Apparently on account of the Allwinner H64 SoC which powers the unit, it will never see an Android release beyond 5.1.  This is very disappointing and not widely publicized information.  I've got nothing against Lollipop, my previous Xiaomi Redmi Note 2 phone ran it without issue and I was happy with that, but times are moving on.

It does suck to have bought a new piece of kit and realize that it's pretty much obsolete out of the box.  Sure, it was cheap but it's not just the cost - it's the time that you put in getting everything set up and working the way you want.  I've picked up minor irritations with certain packages on the Play Store not functioning correctly (ahem MX Player ahem), but haven't yet been able to definitively pin this down to a Marshmallow issue.  I'm obviously aware that you takes your chances with such Chinese products, but really think the already published reviews should be updated with this info so that buyers can make an informed decision.  I hope this info is useful to other (potential) users of the same system.

Thursday, September 21, 2017

VMWare ESXi 6.5a unhandled exception / invalid disk image errors

The default web interface module in the ESXi 6.5a iso release is buggy, get the latest web interface update from this link (direct link to the vib).

Links are borking - here https://labs.vmware.com/flings/esxi-embedded-host-client/

GNS3 + Centos 7.x

This and this (or it doesn't start).

Access VirtualBox guests from host and vice versa

In order to communicate between your VM's and host, add a host-only network adapter on the VM properties.  The IP associated with this adapter will be reachable by the host.

Monday, August 21, 2017

Useful commands for checking Linux hardware specs - memory, CPU, serial number

Server model
# dmidecode | grep -A3 '^System Information'

CPU model
# cat /proc/cpuinfo | grep 'model name' | uniq

Memory summary
# dmidecode -t 17 | grep MB

CPU config - good summary, check socket and core outputs for physicals
# lscpu

CPU config - more detail
# less /proc/cpuinfo

CPU config - just the number of cores, physical and virtual
# nproc

Serial number
# dmidecode -s system-serial-number
# dmidecode | grep Serial

If no root / sudo access (might not work on Debian-based distros, tested on RHEL)
$  lshal | grep system.hardware.serial