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

How to Crack Rar, 7z, and zip files in Linux

If you forget your password for compressed archive (rar, 7z, zip), this program is the solution.This program uses bruteforce algorithm to find correct password. You can specify wich characters will be used in password generations.



Warning: Please don’t use this program for any illegal things!


Preparing your system

First you need to install the following package

#apt-get install libxml2-dev build-essential


Now you need to download the latest version of rarcrack from here

#wget http://surfnet.dl.sourceforge.net/sourceforge/rarcrack/rarcrack-0.2.tar.bz2


Now you have rarcrack-0.2.tar.bz2 file and you need to extract this file

#tar -xjf rarcrack-0.2.tar.bz2

#cd rarcrack-0.2

#make


You must be root to run the following command

#make install


Using Rarcrack

rarcrack your_encrypted_archive.ext [--threads thread_num] [--type rar|zip|7z]


Example

rarcrack something.rar


After the cracking started RarCrack will print the current status of cracking and save it’s to a status file. If you want more specific password character set, you need to run RarCrack to create the XML status file (3 sec).

Enabling Serial Console on /dev/ttyAM1 in TS-7260




I'm running Debian on SD card for this TS-7260. I decided to switch the serial console to the second port which is /dev/ttyAM1 because I'm going to use the first serial /dev/ttyAM0 for my Wavecom GPRS modem. So, I open the /etc/inittab and just realize that serial console on /dev/ttyAM1 is already there.



Then I grab my RS-232 cable and plug it from my /dev/ttyS0 on my PC to the /dev/ttyAM1 on the TS-ARM board... after waiting for some seconds, my minicom shows the login...


Debian GNU/Linux 3.1 ts7000 ttyAM1



ts7000 login:



So, I type root and press the enter... the console returns, "Login incorrect"... WTF!!

How come the serial console on the second port is useless for root? The solution for this is actually very simple. But it took me some minutes to figure it out... hehehe...

Thank god, i've already fixed the ssh, so i can ssh to the board...

$ ssh root@10.1.1.91
$ Password:

The solution is, edit the /etc/securetty file...

$ vi /etc/securetty

And then add the line ttyAM1 under the ttyAM0 in the /etc/securetty file... press escape and type :wq

That's it. Reboot the board. and now i can login with root on my second serial console. Thanks to the guys in #debian at freenode for pointing me to the right direction.

How to Block a Port in Squid Proxy , Ubuntu Linux

Here I will show you how to block a port using squid proxy server and open this port for a selected user.




First you have to open squid configuration
 file /etc/squid/squid.conf

# vi /etc/squid/squid.conf


Locate your Access Control (ACL) section in the file and add the following lines:

acl block_port port 1234
http_access deny block_port
http_access allow all


If you just want to skip a particular IP (192.168.0.101) try as follows:

acl block_port port 1234
acl no_block_port_ip src 192.168.1.5
http_access deny block_port !no_block_port_ip
http_access allow all


Close and save the file.

Restart Your squid proxy server:
# /etc/init.d/squid restart

How to install Graphical Front End for Iptables in Ubuntu /debian Linux : Vuurmuur



Vuurmuur is graphical front end for famous firewall software iptables. You can make complex firewall rules in simple steps. Vuurmuur supports traffic shaping, has powerful monitoring features, which allow the administrator to look at the logs, connections and bandwidth usage in realtime.



install in ubuntu (jaunty and later)

$ sudo apt-get install vuurmuur

How to increase downloading Speed with Prozilla Download Accelerator for Linux

Windows Users are pretty lucky as compared to Linux and Mac users. Since for windows you can get any type of freeware application, utility and tools but incase of Linux most of the time you need to reply on default apps provided with Linux. Same is case of Download Accelerators for Linux.


Download Accelerator optimizes your network settings and lets you to download files with apex 100% to 200% faster downloading speed. ProZilla 2.0.4 is Freeware Linux Download Accelerator which increases your download speed on your Linux machine.

Features of ProZilla 2.0.4 Download Accelerator for Linux

1. Supports FTP & HTTP including redirection (ProZilla & ProzGUI).

2. Resume Supported (ProZilla & ProzGUI).

3. Complete acceleration: The file will be downloaded as fast as possible as your bandwidth allows if not otherwise specified (ProZilla & ProzGUI).

4. Unlike certain other download accelerators available for Linux, this really works.

5. The number of connections that prozilla uses can be specified (ProZilla & ProzGUI).

6. FTPsearch support now permits fetching Mirror locations and pinging them and selecting the fastest server is automatically done (ProZilla & ProzGUI).

7. Downloading the same file in parts from several servers at once to increase speed (ProzGUI).

Screenshots of ProZilla 2.0.4 Download Accelerator for Linux

Prozilla 2.0.4 Console






ProZilla 2.0.4 GUI








Download Freeware ProZilla 2.0.4 for various Linux Flavor and increase downloading speed on linux.

How to Open, Extract and Convert DAA, ISO and BIN Files in Linux with Free PowerISO for Linux

PowerISO provides a free PowerISO for Linux utility which can extract, list, and convert image files in Linux. The image file formats supported by the free PowerISO utility including ISO, BIN, DAA, and some other formats. The Linux based PowerISO is command line utility. For novice Linux users including those trying to handle the image files in web host running CentOS or FreeBSD, here’s a simply guide on how to download, install and use the PowerISO for Linux.

PowerISO for Linux comes with a general help switch which display detailed usage information. To display the help for PowerISO, use the following command:

poweriso -?

To download PowerISO for Linux in Linux, use wget program. Else download the free PowerISO for Linux from here or directly download poweriso-1.1.tar.gz. Uncompress the archive and then upload or transfer to the Linux server.

wget http://poweriso.com/poweriso-1.1.tar.gz

Extract and unpack the tar.gz archive with following command:

tar -zxvf poweriso.tar.gz

Syntax and example usage of PowerISO

To list all files and directories in the root directory of mydisc.iso image file located in /home/user/, use one of the following commands. -r will make the command works recursively, which will display all sub-directories in this case.

./poweriso list /home/user/mydisc.iso /
./poweriso list /home/user/mydisc.iso / -r

To extract files and directories (all the contents) from /home/user/mydisc.daa to /tmp recursively including all sub-directories and its files, use the following command. -od specifies target folder.

./poweriso extract  /home/user/mydisc.daa / -od /tmp

To convert .DAA image file to another disk image format, such as .ISO file, use the following command. For example, the mydisc.daa file is located in /home/user and will be converted and have the converted ISO placed in /tmp folder as mydisc.iso. -o switch specifies destination output image file name, while -ot specifies output image file type. If -ot is not specified, the output image file type will be determined by file name suffix specified by -o parameter.

./poweriso             convert             /home/user/mydisc.daa    -          o   /temp/mydisc.iso -ot iso

How to Extract rar files in Linux

RAR is a proprietary compression format widely used today. It’s supposedly has 30% higher compression rate when compared with WinZip. If you download large torrent then chances are you are are already well acquainted with RAR.


I use RAR on my Windows and Linux boxes everyday and today I’ll show you how to extract RAR files from the Linux command line.

In Linux, to extract a RAR file you would use the unrar command. The unrar binaries are typically not included with the default Linux install so you will have to install them either through the package manager or by downloading binaries from rarlab.com


Let’s get to the HowTo now,



Extract a RAR file into the curren directory.

# unrar e [filename].rar



Extract a RAR file with the full file path.

# unrar x [filename].rar



List contents of a RAR file

# unrar l [filename].rar


Test intergruty of a RAR file

# unrar t [filename].rar

How to Install rar and unrar programs in Linux or Unix

However, I am a linux supporter and I don't want to make you upset while bumping into this blog and didn't really get what you need. So, here is how to install rar and unrar on other linux distributions..see this .How to create and extract rar files in linux




Under Debian Linux, you can use the same apt-get method as follows to install unrar program:
$ apt-get install unrar


If you are using Fedora core Linux then use yum command as follows:
$ yum install unrar


If you are using FreeBSD, you can use:
$ pkg_add -v -r unrar


If any of above, methods is not working, you can download binary package from official rarlab site and choose the right package for your machine... for example, i chose the latest (by the time i write this post):


$ cd /tmp$
wget http://www.rarlab.com/rar/rarlinux-3.7.1.tar.gz

then untar the file:

$ tar -zxvf rarlinux-3.7.1.tar.gz


Both rar and unrar commands are located in rar sub-directory. Just go to rar directory:

$ cd rar$ ./unrar


Now copy rar and unrar to /bin directory:

$ cp rar unrar /bin

Then you can use the same method on creating and extracting rar files in linux in my previous post.



Another thing to add, you can also test the integrity of archive, with this command:

$ unrar t filename.rar

or list the files inside the rar file using this command:

$ unrar l filename.rar

that's it... hope it helps...

How to Create and Extract RAR Files in Linux

I've been sharing mp3s with my close friends for years. We share mp3 files within our same interest in music. As I'm now a total Linux desktop user (I didn't use windows anymore ), I have to find way to create and extract RAR files in Linux since we share the files in compressed RAR files in less than 5MB split.




I always think that my findings in my Linux journey can also help others... So, here is the way to create RAR file in Ubuntu Linux.



First, make sure you have already install unrar and rar which you can get it by issuing this command in your terminal (Application > Accessories > Terminal) ...



$ sudo apt-get install rar unrar







In order to create RAR file, you can just right click on the selected files and click on "Create Archive...", select .rar on the archive dropdown and click on "Create". But, if you wanna extra control, you can use your great powerful terminal to do so. Here's what I do to Create a RAR file splitted to less than 5MB parts...



Open up your terminal and cd to directory with your file to RAR and split. As it is on my /home/dasurendra/Music directory, I'm going there to find my files. [Note: just type the command in bold without the dollar sign]



$ cd /home/dasurendra/Music

$ ls -lh *.mp3

-rw-r--r-- 1 dasurendra dasurendra 6.7M 2008-03-10 16:21 Senandung-nepoli.mp3



then I issue this command to create RAR file containing this mp3 file. I want each part to be less than 4MB...



$ rar a -v4000k Senandung-malam.mp3.rar Senandung-malam.mp3

RAR 3.70 beta 1 Copyright (c) 1993-2007 Alexander Roshal 8 Jan 2007

Shareware version Type RAR -? for help



Evaluation copy. Please register.



Creating archive nepoli..mp3.rar



Adding nepoli.mp3

Calculating the control sum



Creating archive Senandung-malam.mp3.part2.rar



... nepoli..mp3 OK

Calculating the control sum

Done

$



Now I have two parts of rar files. Extracting these files should be more simpler on GUI. Check it out on my previous post on How to Extract RAR files in Ubuntu Linux. In case of many parts, just right click on the first part and choose extract here.



In order to do it in your terminal, just issue this command...



$ unrar e nepoli..mp3.part1.rar .



The program will find for the continuous parts and extract the file. That's all.. Hope it helps you... Good Luck and have fun!

Howto Create .ISO images from CD or DVD in Linux



In Linux computer, we have a simple tool to create CD or DVD .ISO file. This is very helpfull to backup your CD and DVD into ISO images:










To make an ISO from your CD/DVD, place the media in your drive but do not mount it. If it automounts, unmount it.

for dvd:
$ dd if=/dev/dvd of=mydvd.iso

for cdrom:

$ dd if=/dev/cdrom of=mycd.iso


for scsi cdrom:

$ dd if=/dev/scd0 of=mycd.iso



And if you wanna make an ISO from files on your hard drive, create a directory which holds the files you want. Then use the mkisofs command.

mkisofs -o /tmp/mycd.iso /tmp/directory/


This results in a file called cd.iso in folder /tmp which contains all the files and directories in /tmp/directory/.

For more info, see the man pages for mkisofs, losetup, and dd, or see the CD-Writing-HOWTO at http://www.tldp.org/. Enjoy Linux!!

How to Open and Extract .DAA Image Files

DAA stands for Direct Access Archive is PowerISO proprietary and private disk image format which supports compression, password protection, and split into multiple volumes. Which mean .DAA files are exact replicate of a disk, normally CD or DVD, and can be a software program, game, music CD, movie collections, bootable CD and any other CD or DVD discs you can found in the market or simply alternative contents built and put into .DAA image by somebody.

Unfortunately, PowerISO does not release DAA format to third party. It means that you have to download and install PowerISO application program to open or extract data and contents inside the .DAA files. PowerISO is a powerful CD/DVD image file processing tool, which allows you to open, extract, create, edit, compress, encrypt, split and convert ISO, BIN, NRG, CDI, DAA files, and mount these files with internal virtual drive.

Another unfortunate things PowerISO is not a freeware, but a trialware which costs USD $29.95 to register a license and receive serial key. Although there’re cracks or keygens (key makers or key generators) to register the trial copy of PowerISO to fully registered and full functionality available on warez sites, however you no need to violate the copyright law. PowerISO offers users to download free copy of PowerISO for evaluation and try. The unregistered version has all the functions and features that paid registered version has, except that there is a dialog prompts users to register, and users cannot create or edit image files greater than 300MB. So it’s perfectly fine if you just want to open and extract the .DAA files in PowerISO Image Manager, burn the image to disc, or mount the .DAA image to virtual drive without burning to CD or DVD disc.

Download PowerISO version 3.8. For latest version, visit PowerISO download page.

If you’re using Linux, PowerISO also provides a free utility to extract, list, and convert image files of ISO, BIN, DAA, and more. Download poweriso-1.1.tar.gz. Another option for Linux users is AcetoneISO. AcetoneISO (now AcetoneISO2) is a free, open source CD/DVD image manipulator software for Linux with KDE or GNOME that let users mount images formats for Windows or Apple such as ISO, BIN, NRG, MDF, IMG, DAA, DMG and other formats, and then browse, extract, edit, add, convert or perform other tasks on the image. Download AcetoneISO from here.

How to install PHP6 in ubuntu / Debian Linux

The full stable version of PHP6 is not yet released. But pre-built package is available. Early birds can start now. You can install a development snapshot of PHP 6 and preview it for its features and you can check your old scripts ( PHP 6 have some backwards-compatibility issues), so check your existing codes.


Howto Install PHP6 in Ubuntu / debian linux.

First you have to install GCC and GNU make utility

     $sudo apt-get install build-essential

Now PHP6 installation needs some additional libraries

•Apache development headers, such as apache-prefork-dev
•International Component for Unicode (ICU) library, libicu-dev
•The XML2 development headers, libxml2-de etc

You can install the above using
  $ sudo apt-get install apache-prefork-dev libicu-dev libxml2-dev

Now you can download latest PHP6 package from here
 http://snaps.php.net/

$ tar -xzvf php6.0-xxxxxx.tar.gz

Now Change directory to the new directory made by tar and start configuration

$ cd php6.0-xxxxxx
$ sudo ./configure --exec-prefix=/usr
--with-apxs2=/usr/bin/apxs2
--with-config-file-path=/etc/php6
$ sudo make
$ sudo make test
$ sudo make install

How to Burn a CD’s/DVD’s in Ubuntu Linux

GnomeBaker is a Gnome CD/DVD burning application.GnomeBaker is a GTK2/Gnome CD/DVD burning application. I’ve been writing it in my spare time so progress is fairly slow. It’s more of a personal project as I wanted to have a go at developing on Linux and I figured that as I had got this far I may as well let it loose on the world. Maybe someone will like it and use it.


It requires a recent version of cdtools (cdrecord, readcd, cdda2wav and mkisofs), version 2 or greater should be okay. It also requires growisofs for DVD burning.


GnomeBaker Features

Create data CDs.
Blank RW disks.
Burn DVDs.
Copy data CDs.
Copy audio CDs.
Support multisession burning.
Record to and burn from existing CD ISO images.
Can burn via SCSI and ATAPI on Linux kernels 2.4 and 2.6. Basically if cdrecord works, then GnomeBaker will work.
Drag and drop to create data CDs (including drag and drop to/from the Nautilus file manager).
Create audio CDs from existing WAV, MP3, FLAC, and Ogg files.
Integrate with GConf for storage of application settings.


Install GnomeBaker in Ubuntu

sudo aptitude install gnomebaker

This will complete the installation.

After the program is installed, open it by doing Applications--->Sound & Video--->GnomeBaker







Once it opens you should see similar to the following screen





Burn Data CD Using gnomebaker

If you wish to make a Data CD, click Data CD near the bottom.

Add the files and click “Burn”


Burn Audio CD Using gnomebaker

If you want to make an Audio CD, click Audio CD instead of Data CD.

Change the audio CD length from 21 minutes to 80 minutes (a standard CD size) so that you can add a reasonable amount of music to the CD.

Add the music and hit “Burn”.


Burn .iso using gnomebaker

To make an ISO image, click Tools, and then Burn CD/DVD image depending on if you are burning to a CD or DVD. Then you will need to find the location of the ISO image (e.g /home/name/Desktop/someiso.iso)

You can copy another CD/DVD or Audio CD by selecting the option that applies from the Tools menu.


Writing a multisession disk with GnomeBaker

1st Session:

1. Add Files to Data Disk

2. Create data disk. Mode=”default” or “tao” (default should be tao, i.e. track-at-once).

3. Start

4. Ok.

Next session:

1. Import the previous session(s) (Import button). You might have to unmount the disk manually in case you get errors at importing the disk (apparently GnomeBaker can’t handle very well the unmounting of a mounted CD)

2. Add Files to Data Disk

3. Create data disk. Mode=”default” or “tao” (default should be tao, i.e. track-at-once).

4. Start

5. Ok.

And that’s it. You should have now a multisession disk.

How to Install GCC (c/c++) Compiler in Ubuntu Linux

Install package called build-essential is the best way


build-essential contains a list of packages which are essential for building Ubuntu packages including gcc compiler, make and other required tools.


$ sudo apt-get update
$ sudo apt-get upgrade
$ sudo apt-get install build-essential
$ gcc -v
$ make -v

Now, you should able to compile software using C / C++ compilers.

Install .rpm packages in Ubuntu

a
Ubuntu normally use .deb package for application installer. However, if you have an rpm file for a package you wish to install, and if you cannot find a .deb debian package in any of the Ubuntu repositories or elsewhere, you can use the alien package converter application to install the .rpm file.











 "Alien is a program that converts between the rpm, dpkg, stampede slp, and slackware tgz file formats. If you want to use a package from another distribution than the one you have installed on your system, you can use alien to convert it to your preferred package format and install it.






Despite the large version number, alien is still (and will probably always be) rather experimental software. It has been used by many people for many years, but there are still many bugs and limitations.






Alien should not be used to replace important system packages, like sysvinit, shared libraries, or other things that are essential for the functioning of your system. Many of these packages are set up differently by Debian and Red Hat, and packages from the different distributions cannot be used interchangably. In general, if you can’t uninstall the package without breaking your system, don’t try to replace it with an alien version.














How to Install RPM Files Using Alien


Installing Alien






The alien can be installed from the Ubuntu Universe repository by adding the repository to your list of sources and issuing this commands:






$ sudo apt-get update
$ sudo apt-get install alien










Installing the .rpm file






To install the .rpm file, you have to convert it first to a .deb file which then can be installed on Ubuntu.


Assuming that you downloaded the package to your Desktop (~/Desktop is the directory)


You can convert the .rpm to a .deb by using the following commands:










$ cd ~/Desktop
-This will change the directory to your desktop, where you have the .rpm file.










$ sudo alien -k name-of-rpm-file.rpm
- This will convert the .rpm to a .deb.
- The “-k” will keep the version number. Otherwise alien adds a “1″ to the version number.








$ sudo dpkg -i name-of-deb-file.deb-
This will install the .deb package











Feel free to read the alien manpage for more details on how you can convert other kinds of packages and the options available.






That's all for now, Good Luck!!








Finch - How to use Pidgin via Terminal Console

For those who have starts getting in love with Terminal Console in Ubuntu, you may love to be able to do everything from the Terminal console. Even if I previously said, I've already bored with the terminal coz I see it every day...

it is good to know that actually, your terminal can do almost everything you wanna do in your linux box. I just don't like the way it looks and feel because I love art and graphics. I like the eye catchy graphics and also the live cubic desktop effect and so on. Anyway, I would like to share on how to use your Pidgin from terminal console.





I have a lot to say about situations where you only got your terminal console to use programs in linux. But lets keep it short and go straight to the point now. The program to enable you to use Pidgin via Terminal console is called Finch. Finch as in the manual is "A Pimpin’ Penguin console frontend to libpurple Instant Messaging client."



Run this command on your terminal to install finch in Ubuntu:





$ sudo apt-get install finch

After installation, you can now use your Pidgin from the terminal console by running this command on your terminal:

$ finch

As you wish to use terminal, you should already aware that you can't use your mouse (too bad for mousey... LOL). So, you have to be ready with keyboard shortcuts to use this application. Here is the quick list of useful keyboard shortcut to be use within Finch (taken from 'man finch'):



Finch: GNT Shortcut



Shortcut
Description

Alt + a
Bring up a list of available actions. You can use this list to access the accounts window, plugins window, preference window etc.

Alt + n
Go to the next window.

Alt + p
Go to the previous window.

Alt + w
Show the list of windows. You can select and jump to any window from the list.

Alt + c
Close the current window.

Alt + q
Quit.

Alt + m
Start moving a window. Press the cursor keys to move the window. When you are done, press Enter or Escape.

Alt + r
Start resizing a window. Press the cursor keys to resize the window. When you are done, press Enter or Escape.

Alt + d
Dump the contents of the screen in HTML format in a file named "dump.html" in working directory.

Alt + .
Move the position of the current window in the window list one place to the right.

Alt + ,
Move the position of the current window in the window list one place to the left.

Alt + l
Refresh the windows. This is useful after resizing the terminal window.

Alt + 1 2 ... 0
Jump to the 1st, 2nd ... 10th window.

Ctrl + o
Bring up the menu (if there is one) for a window. Note that currently only the buddylist has a menu.

Alt + /
Show a list of available key-bindings for the current widget in focus.

Alt + >
Switch to the next workspace

Alt + <
Switch to the previous workspace

Alt + t
Tag (or untag) the current window

Alt + T
Attached all the tag windows to the current workspace

Alt + s
Show the workspace list

F9
Create a new workspace and switch to it



You may now grab your terminal, try and feel it for yourself. For more information, you may simply call "man finch" and read them. That's all for now mate, Enjoy Ubuntu!!

Simple Linux Socket Programming in Ubuntu

Normally, people start learning programming with some simple typical Hello World sample. However, I'm searching for some challenge as my first try. So, I pick linux socket programming as my quick start. During my short journey on the web, I found this simple tutorial by Rob Tougher. Pretty cool and complete for my starting point... So, if you wanna try it too, feel free to get the code from Rob Tougher's tutorial page and compile it yourself. Modify the codes as you like and learn new things.



While working on the codes downloaded from that page, I found errors while compiling it. Maybe Rob leave this error for us to learn... Anyway, don't worry mates, I'll share the answer... heheheh...



Here's the error on my first try...



dakc@dakc-laptop:~/C-codes/socketserver$ make

g++ -c -o ServerSocket.o ServerSocket.cpp

g++ -c -o Socket.o Socket.cpp

Socket.cpp: In member function ‘int Socket::recv(std::string&) const’:

Socket.cpp:135: error: ‘cout’ is not a member of ‘std’

make: *** [Socket.o] Error 1

dakc@dakc-laptop:~/C-codes/socketserver$





g++ returns this error not because there is no 'cout' in std. But, because we didn't properly declare the std to use 'cout'. In order to fix this, I just add this line...#include in Socket.cpp (you can place it on top, just after all #include codes) and try to 'make' again. I'm sure this error will disappear.



Then, here's the second 'make' trial...



daskc@dakc-laptop:~/C-codes/socketserver$ make

g++ -c -o Socket.o Socket.cpp

g++ -c -o simple_server_main.o simple_server_main.cpp

simple_server_main.cpp: In function ‘int main(int, int*)’:

simple_server_main.cpp:7: error: ‘cout’ is not a member of ‘std’

simple_server_main.cpp:35: error: ‘cout’ is not a member of ‘std’

make: *** [simple_server_main.o] Error 1

dakc@dakc-laptop:~/C-codes/socketserver$





Ups... still got the error... but this time, it is in simple_server_main.cpp... No problem, let's do the same on this file too... save them and here is the third 'make' trial...



dakc@dakc-laptop:~/C-codes/socketserver$ make

g++ -c -o simple_server_main.o simple_server_main.cpp

g++ -o simple_server ServerSocket.o Socket.o simple_server_main.o

g++ -c -o ClientSocket.o ClientSocket.cpp

g++ -c -o simple_client_main.o simple_client_main.cpp

g++ -o simple_client ClientSocket.o Socket.o simple_client_main.o

dakc@dakc-laptop:~/C-codes/socketserver$





SUCCESS!!! without errors anymore... And now, time for testing... open up a terminal and you will see this output when you type ./simple_server



dakc@dakc-laptop:~/C-codes/socketserver$ ./simple_server

running....





Then open another terminal and run the simple client... I run it 3 times...



dakc@dakc-laptop:~/C-codes/socketserver$ ./simple_client

We received this response from the server:

"Test message."

dakc@dakc-laptop:~/C-codes/socketserver$ ./simple_client

We received this response from the server:

"Test message."

dakc@dakc-laptop:~/C-codes/socketserver$ ./simple_client

We received this response from the server:

"Test message."

dakc@dakc-laptop:~/C-codes/socketserver$





Now, I can start modifying the code to learn how it really works. . You can simply untar it by issuing this command in your newly created project folder...



prompt:~$ tar -zxvf simple-socket.tgz





Programming is fun! give it a try if you haven't tried once! Good luck!!

Speed up Ubuntu Linux - Fine tuning Ubuntu

Speed launch your Ubuntu using the following steps


Stop unnecessary Applications and Services that start automatically at boot time.

First Stop the unnecessary softwares that starts at boot time.

System -> Preferences -> Applications startup, a window like the following,



Safely de-select the applications that you want are not started automatically, when you have finished click "Close."

Cancel the automatic start of unnecessary services
Go to System -> Administration -> Services and click in the unlock when prompted to enter the password




Now de-select the services that you don't need at start time.
You can de-select the following
1. Power Management (acpid) - only useful if you use a laptop or a Netbook.
2. Bluetooth device management (blutooth) - you can disable if you do not have bluetooth.
3. Management shortcut keys (hotkey-setup) - if you do not use shortcuts on the keyboard you can disable it.
4. Management Braille display - if you do not need the Braille display so you can disable.

after this click on "Close."

Howto Record Video Using VLC in Ubuntu / Debian



VLC can also used for recording videos during Playback. But, By default the record button is hidden in VLC. First you have to enable the Record Button.


How to Enable Record Button in VLC

Select View->Advanced Control.

The record button will now appear.
Now You can Record movies and videos by clicking on the button dering playback

Clicking again in record button will stop recording

How to add Twitter (twitgin) in Pidgin for Linux

Pidgin does not support Twitter protocol by default. Hence you need to install a plugin for that. There are a lot of plugins available to add twitter in pidgin. microblog-purple is one of such plugins availabe which is open source. It can be intalled in any Linux machine.

This is a plug-in for Pidgin to allow for seamless updating and receiving of Twitter messages. While originally built for Pidgin it works for other LibPurple base clients like Adium and Finch. Currently the plug-in works with Twitter only.


How to install in Ubuntu:

For Ubuntu Users:



sudo echo deb http://ppa.launchpad.net/pidgin-developers/ppa/ubuntu `lsb_release --short --codename` main >> /etc/apt/sources.list

sudo deb-src http://ppa.launchpad.net/pidgin-developers/ppa/ubuntu `lsb_release --short --codename` main >> /etc/apt/sources.list

sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0CF459B8DF37ED8B

Now do this:


sudo apt-get install pidgin-microblog


For Fedora Users:

yum install purple-microblog


How to run this plugin:

First, you need to enable the plugin. Open Pidgin and in Tools > Plugins and check "Twitgin". Then go to Accounts > Manage Accounts, click "Add" and in the "Protocol" List, select TwitterIM. Enter your id and password.