NO SENSE NEWS FROM THE WEB
Posts tagged howto
Howto – Compile Debian/Ubuntu kernel
Mar 4th
Compile Ubuntu kernel
get the tools for building the kernel
apt-get -y install build-essential libncurses5-dev fakeroot kernel-package linux-source
the kernel source code will be in /usr/src/
go to /usr/src and decompress the kernel
tar -xjf linux-source-2.6.28.tar.bz2
and make a symlink
ln -s /usr/src/linux-source-2.6.28 linux
now go the the kernel menu and select what options do you want to compile in your kernel
make menuconfig
next, rebuild the kernel
cd /usr/src/linux
fakeroot make-kpkg --initrd --revision=subzero.1.0 kernel_image
How to find all local IP addresses in python
Jul 26th
I was trying to get all the local IP addresses (public and private) in python , and the standard socket library seems to provide only information about the IP that resolve your hostname. Here is a quick way how to list all your ip from all interfaces in python.
First you need to install the python netifaces module:
On a debian system you can install the module like this:
sudo apt-get install python-netifaces
You’re done, now you can write the code:
from netifaces import interfaces, ifaddresses, AF_INET
for ifaceName in interfaces():
addresses = [i['addr'] for i in ifaddresses(ifaceName)[AF_INET]]
print ‘%s: %s’ % (ifaceName, ‘, ‘.join(addresses))
on my computer I have an output like this:
lo: 127.0.0.1
eth0: 1.1.1.1
eth1: 192.168.0.1
No Sense ?
How to setup a serial connection on MacBook Pro
Jul 18th
An DB9/RJ45 adapter, free USB port, mac ports installed.
Installing
After the serial port is plugged in you USB port you would be able to see the adapter on Apple>About This Mac>More Info
Next we need some drivers for the adapter.
More >
How to create a cisco console cable
Jul 18th
For this operation you need an RJ45 cable and a DB9 adapter.
RJ45 cable
This adapter works with the RJ45 serial port found on most Cisco routers. It also works on some Sun servers.
This is pretty much just like the crossover cable but with a different pinout:
1 – 6
2 – 5
3 – 3
4 – 8
5 – 7
6 – 4
7 – 1
8 – 2
- the other side
DB9 adapter
This is the trickiest part. In order to make your cable compatible with the largest number of serial devices possible, you need to combine a couple pins and split another one. Here is the pinout:
More >




Recent Comments