Showing posts with label ubuntu. Show all posts
Showing posts with label ubuntu. Show all posts

Saturday, May 07, 2022

Thoughts On Ubuntu 22.04 (UPDATED)

 So here I am a few days ago, sitting at my computer, working on a project, and a pop-up appears asking me that Ubuntu 22.04 had been release, asking if I wanted to upgrade to it.  (Yes, I know that I can limit what I am notified of, I actually choose to know when the latest is available).  

I think, "Sure, why not." and clicked through the plethora of buttons to get it up upgrade (agreeing to the upgrade no less than 3 or 4 times). So my machine goes into upgrading and I decide to let it do its thing.  An hour or so later, I return and its at a login prompt, as it had rebooted.  Only, the login page is now dark themed.  Very nice!!!  The upgrade results were starting off on a good note.  

While its just a lot of packages that were upgraded, as well as the underlying software, I will say that there was an extremely annoying side-effect of this upgrade.  I have some projects that I have setup, including having done pip installs of packages and such for the software.  It seems that during the upgrade, all of those packages and settings went away.  Seriously?  Just *POOF*?  What the heck, Ubuntu?  Way to blow away my installs and configs.  

So, I had to spend some time re-setting up the stuff I regularly used (and some I was working on).  All of the items, by the way, were already using Python 3, so nothing except a newer version being installed.  

I just wanted to share this annoyance, in case you are planning on upgrading.  You will need to plan on some extra time, re-setting up some things once the upgrade completes.


UPDATE:  After some research, and noting issues seen on other machines (non-ubuntu) and work systems, this seems to be something related to a python3 upgrade.  On my work Mac, it seems that Python3 upgraded, and put itself in a different location, but did not take on what was previously installed.  It caused a ton of confusion in my system.  There were two different versions of pip3 and two different versions of python3.  It took using 'which -a' to figure this out and zero in on the issue.  In the end, I had to use an alias for each on my Mac to set things right.  

Here on my Ubuntu system though, the python3 upgrade simply wiped out everything that was installed with the previous python3 installation, that wasn't part of the standard library.  Thanks for that.  Way to seriously cause broken software that is used constantly.

Saturday, May 05, 2018

Setup WiFi to auto-connect regardless of logged in state (UPDATED)

There are plenty of times where I would like to start up my desktop machine (running Ubuntu 16.04 LTS) and just have it boot and me log into it via SSH so that I can get some work done.  Well, in order to achieve that wish, you need to have your wifi connection auto-connnect at boot time.

To do this, there are some things you need to do:

1.  Go to your wifi connection in the upper right of your screen and click on "Edit Connections".
2.  Once in there, you need to click on your connected wifi ssid and select "Edit".
3.  Go to the "General" tab and select "All users may connect to this network".  (without this, the rest of this is moot and it will not work)

Ok, that is the only gui portion of this setup.  Next:

4.  Create the file /etc/wpa_supplicant.conf and add the content that follows:

ctrl_interface=DIR=/var/run/wpa_supplicant group=wheel
network={
  ssid="your_connection_ssid"
  scan_ssid=1
  key_mgmt=WPA-PSK
  psk="password"
}
In the above code, you will input your ssid that you would like to connect to and also enter your password for the connection.  If you are using an encryption method other than WPA/WPA2, then you will need to reference the man page for wpa_supplicant.conf.  There are plenty of examples to help you out. 

After you have that file all setup, save it.

5.  Issue the following command on the command line, as root or with sudo:

wpa_supplicant -B -i wlp4s0 -c /etc/wpa_supplicant.conf

You should see a message that says something to the effect that wpa_supplicant initialization was successful.

After you have completed those steps, go ahead and reboot the machine and watch the login screen.  If all is correct and right with the configuration, you should see the wifi connection show as connected.  You can test this by ssh'ing to the machine.  Enjoy!


UPDATE:  I took the opportunity to reinstall my Linux system to go from Ubuntu 16.04 LTS to Ubuntu 18.04.  I know its a bit extreme to do a full re-install, but:

1.  An distribution upgrade wasn't yet available
2.  There wasn't anything I couldn't re-setup on the machine
3.  Ubuntu moved away from Unity to the Gnome desktop, so I wanted everything clean and fresh.

I will say this though, auto-connection of the wifi (seeing as how you tell it how to connect during installation) just WORKS with Ubuntu 18.04.  You just have to make sure to install the openssh-server package.

Friday, November 20, 2015

Creating A Rubygems Mirror On Ubuntu 14.10

So I guess it is apparent that I am on a bit of a kick creating mirrors.  This is because they are creating mirrors internally at work and I want to have a better understanding of how things work (and what is needed to puppetize things). 

Before we can get down to the nitty-gritty of creating the mirror, we have to do a bit of prerequisite work first.   To start with, I will tell you that I am working on a fresh installation of Ubuntu 14.10.  That disclosed, ruby comes installed by default.  Please know that I will be only referencing the

The first thing that we need to get installed is the ruby-dev package.  You can install that with the following command:
$ sudo apt-get install ruby-dev
After you install that, make sure that your system is up to date:
$ sudo apt-get update
$ sudo apt-get upgrade
Now, we need to get a couple of gems installed:
$ sudo gem install net-http-persistent
Next we need to install a whole slew of things (inluding git):
sudo apt-get install git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev python-software-properties libffi-dev
Now it is time to install rbenv.  This tool will provide you the ability to install different versions of ruby (other than the default).  Its handy, so I am including it here for giggles.   Here are the steps to install rbenv (these should be done as you, not sudo/root):
$ git clone git://github.com/sstephenson/rbenv.git ~/.rbenv
- Add $HOME/.rbenv/bin to your PATH variable
- Add eval "$(rbenv init -)" to your .bashrc file
 Now you need to install the rubygems-mirror gem.  This is what is used to create the mirror:
$ sudo gem install rubygems-mirror
After that finishes, you will need to create the the '.mirrorrc' file:
$ vi ~/.gem/.mirrorrc
 In this file, you are going to specify where to grab the gems from and where to put them on your system:
---
- from: http://rubygems.org
  to: ~/path/to/put/the/files
You will need to make sure that you create the directory you specify in the "to:" portion.
After you save the .mirrorrc file and create the directory, you are ready to start mirroring:
$ gem mirror
This is going to take a while.  I ran it and it took several hours to download (and I have a fiber internet connection with 30Mb down).  So, once you start the download, you might as well go do something (watch a movie, read a book, hack on a Raspberry Pi, whatever you feel like.  Just monitor it once in a while to ensure it keeps going successfully.

Warning:  The download is many gigabytes and you are going to need some space for it.

That's it, you now have a mirror of Rubygems that you can reference in offline situations.  Stay tuned and I will put up a post on how to run a server that points to this mirror so that you can put it to good use.
 



 
Creative Commons License
This work is licensed under a Creative Commons Attribution 3.0 License.