Showing posts with label linux. Show all posts
Showing posts with label linux. Show all posts

Saturday 22 July 2023

Mastering Docker Minified Systems: A Step-by-Step Guide with Real Use Cases

Introduction

Docker is a powerful platform for developing, shipping, and running applications. Minified Docker systems are optimized for size and efficiency, making them ideal for production environments where resources are at a premium.

Step 1: Understanding Docker Basics

Before diving into minified systems, ensure you have a solid understanding of Docker concepts like images, containers, volumes, and networks.

Key Commands:

docker pull [image_name] # Download an image from Docker Hub
docker run -d --name [container_name] [image_name] # Run a container in detached mode

Step 2: Creating a Minified Dockerfile

A minified Dockerfile contains only the essential layers needed to run your application.

Example Dockerfile:

FROM alpine:latest
RUN apk add --no-cache python3 py3-pip
COPY . /app
WORKDIR /app
RUN pip install -r requirements.txt
CMD ["python3", "app.py"]

Step 3: Building and Running Your Minified Container

Build your image with the Docker build command, tagging it appropriately.

Build Command:

docker build -t my-minified-app .

Step 4: Optimizing Your Image

Use multi-stage builds to reduce size and remove unnecessary build dependencies.

Multi-Stage Dockerfile:

# Build stage
FROM python:3.8-slim as builder
COPY requirements.txt .
RUN pip install --user -r requirements.txt
# Final stage
FROM python:3.8-alpine
COPY --from=builder /root/.local /root/.local
COPY . .
CMD ["python", "./app.py"]

Step 5: Managing Data and State

For stateful applications, use volumes to persist data.

Volume Command:

docker volume create my_volume
docker run -d -v my_volume:/data my-minified-app

Step 6: Networking and Communication

Link containers and enable communication between them using Docker networks.

Network Commands:

docker network create my_network
docker run -d --net=my_network my-minified-app

Step 7: Deploying to Production

Deploy your containerized application using orchestration tools like Docker Swarm or Kubernetes.

Step 8: Monitoring and Maintenance

Monitor your containers and systems using tools like Docker stats, cAdvisor, or Prometheus.

Conclusion

Mastering Docker minified systems involves understanding Docker fundamentals, optimizing Dockerfiles, managing data, and deploying efficiently.

Further Learning

Remember, practice makes perfect. Start small, iterate, and gradually incorporate these practices into larger projects.

OBs:

Docker is an open platform for developing, shipping, and running applications. Docker enables you to separate your applications from your infrastructure so you can deliver software quickly. 


With Docker, you can manage your infrastructure in the same ways you manage your applications. By taking advantage of Docker’s methodologies for shipping, testing, and deploying code quickly, you can significantly reduce the delay between writing code and running it in production.

Certainly! Here’s an extensive guide titled “Mastering Docker Minified Systems: A Step-by-Step Guide with Real Use Cases.” ]


This guide provides a foundational understanding of working with minified Docker systems. For more in-depth learning, refer to the provided links and continue exploring real-world use cases. Happy Dockering!

Sunday 30 July 2017

How To Install qBittorrent 3.3.7 On Ubuntu 16.04, Ubuntu 15.10 And Ubuntu 14.04 Systems


The - qBittorrent is a torrent client, similar to µTorrent, which was recently ported to the Linux systems. Among others, qBittorrent has built-in search engine for searching in the popular BitTorrent sites, has torrent queueing and prioritizing features, has IP Filtering options, provides a tool for creating torrents and bandwidth limitations.




The latest version available is qBittorrent 3.3.7, which has been released, bringing a few changes only:
  • FEATURE: Delete torrent+files with Shift+Delete
  • BUGFIX: Fix 6-hour speedplot point push rate
  • BUGFIX: Avoid spawning a new explorer.exe process when selecting “Open containing folder”
  • BUGFIX: Fix loading of new geoip db due to an artificial size limit
  • BUGFIX: Better error handling and logging with smtp communication
  • SEARCH: Remove KickassTorrents search engine
  • SEARCH: Remove BTDigg search engine
  • SEARCH: Update Torrentz search engine
For more information, see the full changelog.

Installation instructions:

There isn’t any official qBittorrent PPA or repository, but the community maintains one, so that the users can keep their qBittorrent up to date easily.
The below instructions should work on all the supported Ubuntu systems and derivatives: Ubuntu 16.04 Xenial Xerus, Ubuntu 15.10 Wily Werewolf, Ubuntu 14.04 Trusty Tahr, Linux Mint 17.3 Rosa, Linux Mint 17.2 Rafaela, Linux Mint 17.1 Rebecca, Pinguy OS 14.04, Elementary OS 0.3 Freya, Deepin 2014, Peppermint Five, LXLE 14.04, Linux Lite 2.
$ sudo add-apt-repository ppa:qbittorrent-team/qbittorrent-stable
$ sudo apt-get update
$ sudo apt-get install qbittorrent
If you want to remove qbittorrent, do:
$ sudo apt-get remove qbittorrent




Friday 28 July 2017

Reset Your Forgotten Ubuntu Password in 2 Minutes or Less





If you’ve ever forgotten your password, you aren’t alone… it’s probably one of the most common tech support problems I’ve encountered over the years. Luckily if you are using Ubuntu they made it incredibly easy to reset your password.
image
All it takes is adjusting the boot parameters slightly and typing a command or two, but we’ll walk you through it.
Reset Your Ubuntu Password
Reboot your computer, and then as soon as you see the GRUB Loading screen, make sure to hit the ESC key so that you can get to the menu.
image
Root Shell – Easy Method
If you have the option, you can choose the “recovery mode” item on the menu, usually found right below your default kernel option.
image[3]
Then choose “Drop to root shell prompt” from this menu.
image[6]
This should give you a root shell prompt.
Alternate Root Shell Method
If you don’t have the recovery mode option, this is the alternate way to manually edit the grub options to allow for a root shell.
First you’ll want to make sure to choose the regular boot kernel that you use (typically just the default one), and then use the “e” key to choose to edit that boot option.
image
Now just hit the down arrow key over to the “kernel” option, and then use the “e” key to switch to edit mode for the kernel option.
image
You’ll first be presented with a screen that looks very similar to this one:
image
You’ll want to remove the “ro quiet splash” part with the backspace key, and then add this onto the end:
rw init=/bin/bash
image
Once you hit enter after adjusting the kernel line, you’ll need to use the B key to choose to boot with that option.
image
At this point the system should boot up very quickly to a command prompt.
Changing the Actual Password
You can use the following command to reset your password:
passwd <username>
For example my username being geek I used this command:
passwd geek
image
After changing your password, use the following commands to reboot your system. (The sync command makes sure to write out data to the disk before rebooting)
sync
reboot –f
I found that the –f parameter was necessary to get the reboot command to work for some reason. You could always hardware reset instead, but make sure to use the sync command first.
And now you should be able to login without any issues.

Tuesday 24 March 2015

Error while trying to update Ubuntu 14.04 LTS

Hi all this morning, as usual I was kind updating my Ubuntu and part of my normal system maintenance check up and find this error, while trying to update my system.


It seems strange to me, after a quick google - I found a work around on this website on AskUbuntu forum.. http://askubuntu.com/questions/599112/google-chrome-ppa-upgrade-invalid-signature.

"
Open a terminal and enter the following:
wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
 
That will import Google's updated GPG Key.

You should be able to update the system without any errors.
Source: Google Linux Repositories
"

Friday 15 August 2014

How Edit MySQL connection Error


    Cannot connect to MySQL server over network

Check /etc/my.cnf and make sure you are listening for outside connections. edit the line that starts with bind-address

change:
Code:
bind-address = 127.0.0.1
to:
Code:
#bind-address = 127.0.0.1
make sure mysql is running:
Code:
/etc/init.d/mysql status
if not, start it:
Code:
/etc/init.d/mysql start
check if the ubuntu firewall is running
Code:
sudo ufw status
if it is, allow mysql
Code:
sudo ufw allow mysql
    **************************************************************************



Possibly a security precaution. You could try adding a new administrator account:

mysql> CREATE USER 'monty'@'localhost' IDENTIFIED BY 'some_pass';
mysql> GRANT ALL PRIVILEGES ON *.* TO 'monty'@'localhost'
    ->     WITH GRANT OPTION;
mysql> CREATE USER 'monty'@'%' IDENTIFIED BY 'some_pass';
mysql> GRANT ALL PRIVILEGES ON *.* TO 'monty'@'%'
    ->     WITH GRANT OPTION;


Although as Pascal and others have noted it's not a great idea to have a user with this kind of access open to any IP. If you need an administrative user, use root, and leave it on localhost. For any other action specify exactly the privileges you need and limit the accessibility of the user as Pascal has suggest below.


From the MySQL FAQ:
If you cannot figure out why you get Access denied, remove from the user table all entries that have Host values containing wildcards (entries that contain '%' or '_' characters). A very common error is to insert a new entry with Host='%' and User='some_user', thinking that this allows you to specify localhost to connect from the same machine. The reason that this does not work is that the default privileges include an entry with Host='localhost' and User=''. 
Because that entry has a Host value 'localhost' that is more specific than '%', it is used in preference to the new entry when connecting from localhost! The correct procedure is to insert a second entry with Host='localhost' and User='some_user', or to delete the entry with Host='localhost' and User=''. After deleting the entry, remember to issue a FLUSH PRIVILEGES statement to reload the grant tables.
See also Section 5.4.4, “Access Control, Stage 1: Connection Verification”.

Friday 13 June 2014

How to Install vsftpd on Ubuntu and Add New User



Warning: FTP is inherently insecure. If you must use FTP, consider securing your FTP connection with SSL/TLS. Otherwise, it is best to use SFTP, a secure alternative to FTP.

The first two letters of vsftpd stand for "very secure" and the program was built to have strongest protection against possible FTP vulnerabilities.

Step One—Install vsftpd
You can quickly install vsftpd on your virtual private server in the command line:

sudo apt-get install vsftpd

Once the file finishes downloading, the VSFTP will be on your droplet. Generally speaking, it is already configured with a reasonable amount of security. However, it does provide access on your VPS to anonymous users.

Step Two—Configure vsftpd
Once vsftpd is installed, you can adjust the configuration.

Open up the configuration file:

sudo nano /etc/vsftpd.conf

The biggest change you need to make is to switch the Anonymous_enable from YES to NO:

anonymous_enable=NO

Prior to this change, vsftpd allowed anonymous, unidentified users to access the server's files. This is useful if you are seeking to distribute information widely, but may be considered a serious security issue in most other cases.

After that, uncomment the local_enable option, changing it to yes and, additionally, allow the user to write to the directory.

local_enable=YES
write_enable=YES

Finish up by uncommenting command to chroot_local_user. When this line is set to Yes, all the local users will be jailed within their chroot and will be denied access to any other part of the server.

chroot_local_user=YES
Save and Exit that file.

Because of a recent vsftpd upgrade, vsftpd is "refusing to run with writable root inside chroot". A handy way to address this issue to is to take the following steps:

Create a new directory within the user's home directory
mkdir /home/username/files
Change the ownership of that file to root
chown root:root /home/username

Make all necessary changes within the "files" subdirectory
Then, as always, restart:

sudo service vsftpd restart
Step Three—Access the FTP server
Once you have installed the FTP server and configured it to your liking, you can now access it.

You can reach an FTP server in the browser by typing the domain name into the address bar and logging in with the appropriate ID. Keep in mind, you will only be able to access the user's home directory.

ftp://example.com
Alternatively, you can reach the FTP server on your virtual server through the command line by typing:

ftp example.com

Then you can use the word, "exit," to get out of the FTP shell.



Adding New Users To vsftpd

I found it rather strange that there arent any good tutorial that can explain how to add new users to vftpd. Google gives few results but most of them are trial and error method. So i decided to write this post after spending 1 hr trying to accomplish this simple task.

#edit /etc/vsftpd.conf or /opt/etc/vsftpd.conf
Open the vsftpd.conf file and search for chroot_list_enable=YES
Make sure it is YES. Do the same for the following variables
chroot_list_file=/etc/vsftpd.chroot_list or /opt/etc/vsftpd.chroot_list
chroot_list_enable=YES
Save and close the file

Create vsftpd.chroot_list in /etc/ or /opt/etc/
Add the username you want to export to ftp.
IMP: The user must already be a system user with a valid passwd. You must be able to find /home/
If the user you want to add is not a system user then create that user first before editing the above file.
#adduser 
#passwd 

Restart the vsftpd server using /etc/init.d/vsftpd restart or service vsftpd restart
Now you can log into ftp using the new user.



Tuesday 1 October 2013

How to Install Ruby & Rails on CentOS, Fedora or RedHat

#get root access
$su -
$ cd /tmp
 
#Remove old Ruby
$ yum remove ruby
# Install dependencies
$ yum groupinstall "Development Tools"
$ yum install zlib zlib-devel
$ yum install openssl-devel
$ wget http://pyyaml.org/download/libyaml/yaml-0.1.4.tar.gz
$ tar xzvf yaml-0.1.4.tar.gz
$ cd yaml-0.1.4
$ ./configure
$ make
$ make install
# Install ruby
$ wget http://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p194.tar.gz
$ tar zxf ruby-1.9.3-p194.tar.gz
$ cd ruby-1.9.3-p194
$ ./configure
$ make
$ make install
# Update rubygems
$ gem update --system
$ gem install bundler
#Test ruby and rubygems are working
#Close shell and reopen for changes to take effect
$ruby -v
$gem --version
# Rails
$ yum install sqlite-devel
$ gem install rails
$ gem install sqlite3

Thursday 12 September 2013

How To Setup a Local Clamav Update Server

1.Install base Ubuntu Server (we use 8.04 LTS)

2.Choose the Openssh and LAMP server options

3.Enable the backports reposistory in /etc/apt/sources.list, to get the latest client

4.Change the Document Root for Apache to /var/lib/clamav/

5.Create a daily update script to get the main.cvd and daily.cvd file
I called mine clamup.sh, and below is a listing of it's content:

#!/bin/sh
cd /tmp
wget http://database.clamav.net/daily.cvd
wget http://database.clamav.net/main.cvd
mv main.cvd /var/lib/clamav/
mv daily.cvd /var/lib/clamav/
apt-get update && apt-get upgrade -y && /etc/init.d/clamav-freshclam restart


The last line updates the system, and restarts freshclam.
If you don't want automatic updates, you can replace that line with:

/etc/init.d/clamav-freshclam restart


6. Create a script to update the 'thru the day' virus updates
I called mine clamsubver.sh, and below is the listing of it's content:

#!/bin/sh
cd /tmp
ver=`host -t txt current.cvd.clamav.net > /tmp/version.txt && awk -F":" '{print $3}' /tmp/version.txt`
dl="daily-$ver.cdiff"
wget http://database.clamav.net/$dl
mv /tmp/$dl /var/lib/clamav/


This script checks the Clam DNS record for latest version, and then downloads it.

7.setup cron to run both scripts. Mine looks like this:

59 11 * * * /sbin/clamup.sh
15 * * * * /sbin/clamsubver.sh


8.Now point your clients to update from your server, and watch it work.

All connections (or lack thereof) can be tracked in the server's apache access.log in /var/log/apache2

The Original Article was published on Ubuntu Forums by bigmeanogre 

Tuesday 10 September 2013

Linux Containers on Virtualbox - Disposal Boxes by Michal Migurski's

Hey look, a month went by and I stopped blogging because I have a new job. Great.
One of my responsibilities is keeping an eye on our sprawling Github account, currently at 326 repositories and 151 members. The current fellows are working on a huge number of projects and I frequently need to be able to quickly install, test and run projects with a weirdly-large variety of backend and server technologies. So, it’s become incredibly important to me to be able to rapidly spin up disposable Linux web servers to test with. Seth clued me in to Linux Containers (LXC) for this:
LXC provides operating system-level virtualization not via a full blown virtual machine, but rather provides a virtual environment that has its own process and network space. LXC relies on the Linux kernel cgroups functionality that became available in version 2.6.24, developed as part of LXC. … It is used by Heroku to provide separation between their “dynos.”
I use a Mac, so I’m running these under Virtualbox. I move around between a number of different networks, so each server container had to have a no-hassle network connection. I’m also impatient, so I really needed to be able to clone these in seconds and have them ready to use.
This is a guide for creating an Ubuntu Linux virtual machine under Virtualbox to host individual containers with simple two-way network connectivity. You’ll be able to clone a container with a single command, and connect to it using a simple <container>.local host name.

The Linux Host

First, download an Ubuntu ISO. I try to stick to the long-term support releases, so I’m using Ubuntu 12.04 here. Get a copy of Virtualbox, also free.
Create a new Virtualbox virtual machine to boot from the Ubuntu installation ISO. For a root volume, I selected the VDI format with a size of 32GB. The disk image will expand as it’s allocated, so it won’t take up all that space right away. I manually created three partitions on the volume:
  1. 4.0 GB ext4 primary.
  2. 512 MB swap, matching RAM size. Could use more.
  3. All remaining space btrfs, mounted at /var/lib/lxc.
Btrfs (B-tree file system, pronounced “Butter F S”, “Butterfuss”, “Better F S”, or “B-tree F S") is a GPL-licensed experimental copy-on-write file system. It will allow our cloned containers to occupy only as much disk space as is changed, which will decrease the overall file size of the virtual machine.
During the OS installation process, you’ll need to select a host name. I used “ubuntu-demo” for this demonstration.

Host Linux Networking

Boot into Linux. I started by installing some basics, for me: git, vim, tcsh, screen, htop, and etckeeper.
Set up /etc/network/interfaces with two bridges for eth0 and eth1, both DHCP. Note that eth0 and eth1 must be commented-out, as in this sample part of my /etc/network/interfaces:
## The primary network interface
#auto eth0
#iface eth0 inet dhcp

auto br0
iface br0 inet dhcp
        dns-nameservers 8.8.8.8
        bridge_ports eth0
        bridge_fd 0
        bridge_maxwait 0

auto br1
iface br1 inet dhcp
        bridge_ports eth1
        bridge_fd 0
        bridge_maxwait 0
Back in Virtualbox preferencese, create a new network adapter and call it “vboxnet0”. My settings are 10.1.0.1, 255.255.255.0, with DHCP turned on.


Shut down the Linux host, and add the secondary interface in Virtual box. Choose host-only networking, the vboxnet0 adapter, and “Allow All” promiscuous mode so that the containers can see inbound network traffic.

The primary interface will be NAT by default, which will carry normal out-bound internet traffic.
  1. Adapter 1: NAT (default)
  2. Adapter 2: Host-Only vboxnet0
Start up the Linux host again, and you should now be able to ping the outside world.
% ping 8.8.8.8

PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
64 bytes from 8.8.8.8: icmp_req=1 ttl=63 time=340 ms
…
Use ifconfig to find your Linux IP address (mine is 10.1.0.2), and try ssh’ing to that address from your Mac command line with the username you chose during initial Ubuntu installation.
% ifconfig br1

br1       Link encap:Ethernet  HWaddr 08:00:27:94:df:ed  
          inet addr:10.1.0.2  Bcast:10.1.0.255  Mask:255.255.255.0
          inet6 addr: …
Next, we’ll set up Avahi to broadcast host names so we don’t need to remember DHCP-assigned IP addresses. On the Linux host, install avahi-daemon:
% apt-get install avahi-daemon
In the configuration file /etc/avahi/avahi-daemon.conf, change these lines to clarify that our host names need only work on the second, host-only network adapter:
allow-interfaces=br1,eth1
deny-interfaces=br0,eth0,lxcbr0
Then restart Avahi.
% sudo service avahi-daemon restart
Now, you should be able to ping and ssh to ubuntu-demo.local from within the virtual machine and your Mac command line.

No Guest Containers

So far, we have a Linux virtual machine with a reliable two-way network connection that’s resilient to external network failures, available via a meaningful host name, and with a slightly funny disk setup. You could stop here, skipping the LXC steps and use Virtualbox’s built-in cloning functionality or something like Vagrant to set up fresh development environments. I’m going to keep going and set up LXC.

Linux Guest Containers

Install LXC.
% sudo apt-get lxc
Initial LXC setup uses templates, and on Ubuntu there are several useful ones that come with the package. You can find them under /usr/lib/lxc/templates; I have templates for ubuntu, fedora, debian, opensuse, and other popular Linux distributions. To create a new container called “base” use lxc-create with a chosen template.
% sudo lxc-create -n base -t ubuntu
This takes a few minutes, because it needs retrieve a bunch of packages for a minimal Ubuntu system. You’ll see this message at some point:
##
# The default user is 'ubuntu' with password 'ubuntu'!
# Use the 'sudo' command to run tasks as root in the container.
##
Without starting the container, modify its network adapters to match the two we set up earlier. Edit the top of /var/lib/lxc/base/config to look something like this:
lxc.network.type=veth
lxc.network.link=br0
lxc.network.flags=up
lxc.network.hwaddr = 00:16:3e:c2:9d:71

lxc.network.type=veth
lxc.network.link=br1
lxc.network.flags=up
lxc.network.hwaddr = 00:16:3e:c2:9d:72
An initial MAC address will be randomly generated for you under lxc.network.hwaddr, just make sure that the second one is different.
Modify the container’s network interfaces by editing /var/lib/lxc/base/rootfs/etc/network/interfaces (/var/lib/lxc/base/rootfs is the root filesystem of the new container) to look like this:
auto eth0
iface eth0 inet dhcp
        dns-nameservers 8.8.8.8

auto eth1
iface eth1 inet dhcp
Now your container knows about two network adapters, and they have been bridged to the Linux host OS virtual machine NAT and host-only adapters. Start your new container:
% sudo lxc-start -n base
You’ll see a normal Linux login screen at first, use the default username and password “ubuntu” and “ubuntu” from above. The system starts out with minimal packages. Install a few so you can get around, and include language-pack-en so you don’t get a bunch of annoying character set warnings:
% sudo apt-get install language-pack-en
% sudo apt-get install git vim tcsh screen htop etckeeper
% sudo apt-get install avahi-daemon
Make a similar change to the /etc/avahi/avahi-daemon.conf as above:
allow-interfaces=eth1
deny-interfaces=eth0
Shut down to return to the Linux host OS.
% sudo shutdown -h now
Now, restart the container with all the above modifications, in daemon mode.
% sudo lxc-start -d -n base
After it’s started up, you should be able to ping and ssh to base.local from your Linux host OS and your Mac.
% ssh ubuntu@base.local

Cloning a Container

Finally, we will clone the base container. If you’re curious about the effects of Btrfs, check the overall disk usage of the /var/lib/lxc volume where the containers are stored:
% df -h /var/lib/lxc

Filesystem      Size  Used Avail Use% Mounted on
/dev/sda3        28G  572M   26G   3% /var/lib/lxc
Clone the base container to a new one, called “clone”.
% sudo lxc-clone  -o base -n clone
Look at the disk usage again, and you will see that it’s not grown by much.
% df -h /var/lib/lxc

Filesystem      Size  Used Avail Use% Mounted on
/dev/sda3        28G  573M   26G   3% /var/lib/lxc
If you actually look at the disk usage of the individual container directories, you’ll see that Btrfs is allowing 1.1GB of files to live in just 573MB of space, representing the repeating base files between the two containers.
% sudo du -sch /var/lib/lxc/*

560M /var/lib/lxc/base
560M /var/lib/lxc/clone
1.1G total
You can now start the new clone container, connect to it and begin making changes.
% sudo lxc-start -d -n clone
% ssh ubuntu@clone.local

Conclusion

I have been using this setup for the past few weeks, currently with a half-dozen containers that I use for a variety of jobs: testing TileStache, installing Rails applications with RVM, serving Postgres data, and checking out new packages. One drawback that I have encountered is that as the disk image grows, my nightly time machine backups grow considerably. The Mac host OS can only see the Linux disk image as a single file.
On the other hand, having ready access to a variety of local Linux environments has been a boon to my ability to quickly try out ideas. Special thanks again to Seth for helping me work through some of the networking ugliness.

Further Reading

Tao of Mac has an article on a similar, but slightly different Virtualbox and LXC setup. They don’t include the promiscuous mode setting for the second network adapter, which I think is why they advise using Avahi and port forwarding to connect to the machine. I believe my way here might be easier.
Shift describes a Vagrant and LXC setup that skips Avahi and uses a plain hostnames for internal connectivity.

The Owner of this post is Michal Migurski
Find is Blog here http://mike.teczno.com/notes/disposable-virtualbox-lxc-environments.html 

Monday 9 September 2013

Vulnerabilities on Ubuntu ..



A security issue affects these releases of Ubuntu and its derivatives:

- Ubuntu 13.04
- Ubuntu 12.10
- Ubuntu 12.04 LTS
- Ubuntu 10.04 LTS

Summary:

Fraudulent security certificates could allow sensitive information to
be exposed when accessing the Internet.

Software Description:
- python-httplib2: comprehensive HTTP client library written for Python

Details:

It was discovered that httplib2 only validated SSL certificates on the
first request to a connection, and didn't report validation failures on
subsequent requests. If a remote attacker were able to perform a
man-in-the-middle attack, this flaw could possibly be exploited in certain
scenarios to alter or compromise confidential information in applications
that used the httplib2 library.

Update instructions:

The problem can be corrected by updating your system to the following
package versions:

Ubuntu 13.04:
  python-httplib2                 0.7.7-1ubuntu0.1

Ubuntu 12.10:
  python-httplib2                 0.7.4-2ubuntu0.1

Ubuntu 12.04 LTS:
  python-httplib2                 0.7.2-1ubuntu2.1

Ubuntu 10.04 LTS:
  python-httplib2                 0.7.2-1ubuntu2~0.10.04.2

In general, a standard system update will make all the necessary changes.

References:
  http://www.ubuntu.com/usn/usn-1948-1
  CVE-2013-2037

Package Information:
  https://launchpad.net/ubuntu/+source/python-httplib2/0.7.7-1ubuntu0.1
  https://launchpad.net/ubuntu/+source/python-httplib2/0.7.4-2ubuntu0.1
  https://launchpad.net/ubuntu/+source/python-httplib2/0.7.2-1ubuntu2.1
  https://launchpad.net/ubuntu/+source/python-httplib2/0.7.2-1ubuntu2~0.10.04.2
..

To make sure your system is not vulnerable go on to Linux terminal and type " locate python-httplib2" then navigate into the file with command cd  in my case was  " cd /usr/share/sbin/doc/python-httplib2" Read the copyright documents ... with "less copyright" command and then ...

Upgrade it by running "sudo apt-get install python-httplib2 "

******************************************************************************

==========================================================================
Ubuntu Security Notice USN-1949-1
September 10, 2013

imagemagick vulnerability
==========================================================================

A security issue affects these releases of Ubuntu and its derivatives:

- Ubuntu 13.04
- Ubuntu 12.10

Summary:

ImageMagick could be made to crash or run programs as your login if it
opened a specially crafted file.

Software Description:
- imagemagick: Image manipulation programs and library

Details:

It was discovered that ImageMagick incorrectly handled decoding GIF image
comments. If a user or automated system using ImageMagick were tricked into
opening a specially crafted GIF image, an attacker could exploit this to
cause a denial of service or possibly execute code with the privileges of
the user invoking the program.

Update instructions:

The problem can be corrected by updating your system to the following
package versions:

Ubuntu 13.04:
  libmagick++5                    8:6.7.7.10-5ubuntu2.1
  libmagickcore5                  8:6.7.7.10-5ubuntu2.1

Ubuntu 12.10:
  libmagick++5                    8:6.7.7.10-2ubuntu4.1
  libmagickcore5                  8:6.7.7.10-2ubuntu4.1

In general, a standard system update will make all the necessary changes.

References:
  http://www.ubuntu.com/usn/usn-1949-1
  CVE-2013-4298

Package Information:
  https://launchpad.net/ubuntu/+source/imagemagick/8:6.7.7.10-5ubuntu2.1
  https://launchpad.net/ubuntu/+source/imagemagick/8:6.7.7.10-2ubuntu4.1



Friday 23 August 2013

Monday 19 August 2013

How To Install VMWare Tools v4 on Ubuntu 12.04 LTS Server



How To Install VMWare Tools v4 on Ubuntu 12.04 LTS Server and 12.10 Server

Written: March 13, 2012
Originally posted by: Justin Schier
Last Updated: October 24, 2012
Tested With: Ubuntu 12.10 Server, Ubuntu 12.04 LTS Server, Ubuntu 12.04.1 LTS Server, Ubuntu 11.10 Server

All the guides I found on the Internet, including VMWare’s website were outdated in some way, so I decided to write a guide of my own. I just went through these steps from start to finish on a fresh server and had no problems. In about 5 minutes, you will be able to install VMWare Tools on Ubuntu Server.
  1. Use Install VMWare Tools option in VMWare Client to attach media
    ubuntu vmware tools install 12.10 
  2. Update the server
  3. Create the mount point
  4. Mount the ISO

    You should see the message: mount: block device /dev/sr0 is write-protected, mounting read-only
  5. Change Directory
  6. Copy the tar file to your /tmp directory
  7. Install Build tools if necessary
  8. Change Directory
  9. Unmount the ISO
  10. Expand the tar
  11. Change Directory
  12. To prevent a potential error in the install script on Ubuntu 11.10+, create a special directory
    Unable to create symlink “/usr/lib64/libvmcf.so” pointing to file ”/usr/lib/vmware-tools/lib64/libvmcf.so/libvmcf.so”.
  13. Run the Install Script. The -d flag automatically answers the default to all questions. To customize it, just omit the -d.
  14. Reboot
Let me know if this worked for you!
Also, please follow me on Twitter: @justinschier

This is "How to do Computing" for everyday usage ...

How to Create a Ansible Lab on your Local Machine using Vagrant in 5 min using ChatGPT

This is an exciting experiment of mine as DevOps. As I am experimenting with the Tools available ... So, the quest is to " Vagrantfile ...