Linux

Installing Peer Guardian on Ubuntu

2

Some of you might be familiar with an application called PeerBlock which is made specifically for Windows. You may also remember the older version called PeerGuardian which is also made by Phoenix Labs. Whatever the reason is for needing these types of applications, I thought it might be useful for the Linux beginners to know how to install and use this application.

Step 1

First and foremost, we need to somehow download this application to be able to use it. We have two possible places we can download from:
Debian at http://moblock-deb.sourceforge.net
Ubuntu at Debian at http://moblock-deb.sourceforge.net
Ubuntu at https://launchpad.net/~jre-phoenix/+archive/ppa

For sake of simplicity, we'll just download the files from sourceforge.

Step 2

Open Terminal (Control + Shift + I is a shortcut to opening terminal)
We need to install some additional libraries for us to actually easily package this software into something we can use.
Copy and paste the following into terminal and run each command.

sudo apt-get install devscripts debhelper po-debconf zlib1g-dev 
sudo apt-get install libnetfilter-queue-dev libnfnetlink-dev libdbus-1-dev libqt4-dev

Step 3

Extract the tarball archive so we can access the files inside of the folder:

tar xvfz pgl-2.1.3.tar.gz

Step 4

Navigate into the extracted directory:

cd pgl-2.1.3

Now we want to compile all of the files into deb packages so we can install them. Issue the following command inside the pgl-2.1.3 folder:

sudo debuild --no-lintian -us -uc -tc -b

Look within the containing directory (for me it was Downloads) and you will see the following deb packages created for us:

  • pglcmd_2.1.3-1_all.deb
  • pgld_2.1.3-1_*.deb
  • pgld-dbg_2.1.3-1_*.deb
  • pgl-gui_2.1.3-1_*.deb
  • pgl-gui-dbg_2.1.3-1_*.deb

Note: * should represent the architecture your CPU is. In my case, it's amd64 but for you it might be i386, x86_64, or something different.

Step 5

Now we finally get to utilize those newly created deb packages and bring the application to life!
Run the following commands in terminal:

sudo dpkg -i pgld_2.1.3-1_*.deb
sudo dpkg -i pglcmd_2.1.3-1_all.deb
sudo dpkg -i pgld-dbg_2.1.3-1_*.deb
sudo dpkg -i pgl-gui_2.1.3-1_*.deb
sudo dpkg -i pgl-gui-dbg_2.1.3-1_*.deb

Note: the wildcards (*) should work just fine for installing these packages. In the event they are not then replace them with the necessary text before .deb and after 2.1.3-1_

Once all of the deb packages have been install then you have PeerGuardian on your system! Hurray! We can run peerguardian by searching for it on our desktop (click the ubuntu home button for those with the default Unity DE) or we can start the application via the following:

# use this command for launching the GUI
sudo /usr/bin/pgl-gui
# use this command for the command-line application
sudo /usr/bin/pglcmd start
# ensure the application works correctly
sudo /usr/bin/pglcmd test
# we can also view stats on the applciation
sudo /usr/bin/pglcmd stats
# stop the application by running
sudo /usr/bin/pglcmd stop

Adding Oracle JRE and JDK to Ubuntu 11.10

1

Problem: Need to install Oracle JRE and JDK and NOT Open JDK/JRE on Debian-style distros.

Solution:
After thumbing through countless pages I finally found the answer!

sudo add-apt-repository ppa:ferramroberto/java
sudo apt-get update
sudo apt-get install sun-java6-jre sun-java6-plugin sun-java6-fonts

The code above will add java to your repository (found in /etc/apt/sources.list.d/) and store it on your file system.

We need to update aptitude so it recognizes the new repository location, so we issue the sudo apt-get update command

Finally, we need to actually install the desired software. Since ubuntu officially doesn't have the repository automatically listed we needed to add a new location. When we issue the apt-get install packagename command aptitude will query the list of known repository locations that come pre-bundled with Ubuntu or any Debian-style distro (Ubuntu included).

For those that are really interested, we can quickly cat the .list file and we will see the following:

deb http://ppa.launchpad.net/ferramroberto/java/ubuntu oneiric main
deb-src http://ppa.launchpad.net/ferramroberto/java/ubuntu oneiric main

The addition of the new repository location creates the file in the /etc/apt/sources.list.d/ as mentioned previously.

Installing Microsoft Fonts on Linux Ubuntu

0

Even with the most recent version of Ubuntu, it still lacks the truetype font kits that come with Windows. Sometimes we might want to use Trebuchet MS, Verdana, or — heaven forbid — Arial.

This is a quick tutorial on how to install the most common windows fonts on your Ubuntu OS. We will need to use the power of terminal. For all the newbies out there fret not! Just follow closely and you will have no issues!

What We'll be Doing

We're going to be installing the msttcorefonts package which consists of the following:

  • Andale Mono
  • Arial Black
  • Arial (Bold, Italic, Bold Italic)
  • Comic Sans MS (Bold)
  • Courier New (Bold, Italic, Bold Italic)
  • Georgia (Bold, Italic, Bold Italic)
  • Impact
  • Times New Roman (Bold, Italic, Bold Italic)
  • Trebuchet (Bold, Italic, Bold Italic)
  • Verdana (Bold, Italic, Bold Italic)
  • Webdings

Step 1: Open Terminal

Since we'll be using terminal we need to open it. For those running Ubuntu 11.04 (or later), you can simply search for terminal via the search function in the upper left-hand corner (click on the ubuntu icon). On older versions of Ubuntu you can look for terminal under System to find Terminal.

Step 2: Install the fonts

Type the following command

$sudo apt-get install msttcorefonts

You will be promoted to agree to various licenses, just scroll down and select OK and hit enter.

Step 3: Flush Font Cache

After all new fonts are installed, we need to flush the font cache via the following command:

$sudo fc-cache -fv

Installing the Missing Font

For some reason this package is mission the Tahoma font, not sure why. But to install the Tahoma font follow the instructions below:

Step 4: Installing Tahoma

Download the font here

Locate the IELPKTH.CAB file via the GUI controls and move the font to the desktop for ease of use.
Create a folder in the desktop to house all the files that we'll need to use, call it something like tahoma.

Note: you can do this via terminal as well via the following commands:
If cd Desktop isn't working then you'll need to find your way back to your user home, typically /home/%username%/Desktop/

cd Desktop
mkdir tahoma
mv IELPKTH.CAB tahoma

Step 5: Extracting the Goods

Once we have the .CAB file, we need a way to extract the goods inside since it's a complication of files. We need to use a utility called cabextract. This utility may or may not be installed, we can see by issuing the following command:

cabextract IELPKTH.CAB

If your are promoted to install cabextract, then do so now. Otherwise, the utility will run and the .CAB file will extract to the tahoma directory we created on our Desktop.

Step 6: Copy the Font

We need to copy the two .ttf files from our extracted .CAB file into the msttcorefonts file. We can do this by issuing the following command:

sudo cp *.ttf /usr/share/fonts/truetype/msttcorefonts/

Step 7: Flush the Cache again

Flush the cache again.

$sudo fc-cache -fv

Finally

To make sure our Ubuntu OS is recognizing the fonts we recently installed, open Libre Office, Open Office, or your favorite word editor and verify the fonts show in our font list and show correctly.

Go to Top