I rarely find a case where Fedora/Centos/Rhel lacks a package for something on debian/ubuntu. In fact as mature package management systems become increasingly common such as emerge,yum, dpkg/apt, yast, and pkgsrc. I expect this will become increasingly rare amongst distro's as time goes on. In the long run there are few solutions but there is one I prefer... Alien :)
Alien
Website: http://kitenet.net/~joey/code/alien/
Source URL: http://packages.debian.org/unstable/source/alien
GIT: git://git.kitenet.net/alien
Apt: sudo apt-get install alien
Conversion of an *.deb file to *.rpm file.
Usage:
workbox:~/Downloads$ wget https://sourceforge.net/projects/debreate/files/debreate/0.7/debreate_0.7.0-0_all.deb/download
workbox:~/Downloads$ sudo alien -r --scripts debreate_0.7.0-0alpha5_all.deb
debreate-0.7.0-1.noarch.rpm generated
Most notably this conversion tool works with the following formats:
Rhel/Centos/Fedora : rpm
Debian/Ubuntu : deb
Stampede : slp
Slackware/Slax : tgz
Solaris/*BSD : pkg
Enjoy!
Wednesday, August 25, 2010
Friday, August 6, 2010
Linux: TRK ( Trinity Rescue Kit )
This week my company fired our SEO guy, Eh.. That wasnt pretty and such. Most notably when you have those situations where it was not under great terms you find "repurposing" there work station becomes a nightmare.
The set up was a machine with Windows 7, and the only user was the guy who was
fired and his password. His password of course wasn't documented anywhere so I was left to the task of getting in.
In another life I was into stuff like bypassing and all that jazz. I went out on the internet and with in a few searches I found the right "tool" for the "job".
Trinity Rescue Kit
Homepage Url: http://trinityhome.org/Home/index.php?wpid=1&front_id=12
Download Url: http://trinityhome.org/Home/index.php?wpid=165&front_id=12
I did the following:
1. Downloaded the trk iso & put my thumbdrive(2gb) in the machine.
2. Mounted the iso to a VM on virtualbox (Non-OSE)
3. Enabled usb passthrough in virtualbox for my thumbdrive.
4. Booted the iso, and hit the default boot option
5. At command promt:
$> mountallfs
$> trk2nfs -d /dev/sda -s 1024
~~~~ Waited for it to do its thing ~~~~
$> reboot
6. turned off the virtual machine and removed my thumbdrive.
7. moved over the the former employee's work station.
8. booted machine, and edited the bio's to boot from the thumbdrive.
9. let trk start up and then selected default boot.
10. At command promt:
$> mountallfs
$> winpass
4) to unlock the administrators account (might have this to do a few times it didnt stick the first time.
$> winpass
3) to wipe the password for that account.
$> reboot
11. wait for it shutdown.
12. pull thumbdrive and let system boot normally.
13. Login as administrator, reset account passwords and such.
^^ Have fun
The set up was a machine with Windows 7, and the only user was the guy who was
fired and his password. His password of course wasn't documented anywhere so I was left to the task of getting in.
In another life I was into stuff like bypassing and all that jazz. I went out on the internet and with in a few searches I found the right "tool" for the "job".
Trinity Rescue Kit
Homepage Url: http://trinityhome.org/Home/index.php?wpid=1&front_id=12
Download Url: http://trinityhome.org/Home/index.php?wpid=165&front_id=12
I did the following:
1. Downloaded the trk iso & put my thumbdrive(2gb) in the machine.
2. Mounted the iso to a VM on virtualbox (Non-OSE)
3. Enabled usb passthrough in virtualbox for my thumbdrive.
4. Booted the iso, and hit the default boot option
5. At command promt:
$> mountallfs
$> trk2nfs -d /dev/sda -s 1024
~~~~ Waited for it to do its thing ~~~~
$> reboot
6. turned off the virtual machine and removed my thumbdrive.
7. moved over the the former employee's work station.
8. booted machine, and edited the bio's to boot from the thumbdrive.
9. let trk start up and then selected default boot.
10. At command promt:
$> mountallfs
$> winpass
4) to unlock the administrators account (might have this to do a few times it didnt stick the first time.
$> winpass
3) to wipe the password for that account.
$> reboot
11. wait for it shutdown.
12. pull thumbdrive and let system boot normally.
13. Login as administrator, reset account passwords and such.
^^ Have fun
Friday, July 30, 2010
How memory Profiles differ from VPS/Guest Host/Actual System
Device profiles are able to actually help us determine the locations of memory but also can help you profile a system. In this post Im providing some outputs of VPS/Guest Host/Actual Systems so you can see the difference.
OpenVZ:
root@bucket:~# lshw -short -class memory
H/W path Device Class Description
========================================
/0/0 memory 1GiB System memory
Above is our OpenVZ Linux Box. Not much to see here its a singular
memory channel 1GB of ram.
----------------------------------------------------------------
VirtualBox Guest Host:
dnsbox@dnsbox:~$ sudo lshw -short -class memory
[sudo] password for dnsbox:
H/W path Device Class Description
=====================================================
/0/0 memory 128KiB BIOS
/0/1 memory 511MiB System memory
/0/2/0 memory 128KiB L1 cache
/0/2/1 memory 1MiB L2 cache
Similar to the OpenVZ as in 0/1 being a singular memory channel
however abit more robust in providing Cache and L1/L2.
CPUs Cache:
/0/2/0 memory 128KiB L1 cache
/0/2/1 memory 1MiB L2 cache
----------------------------------------------------------------
Real Host:
melinko2003@workbox:~$ sudo lshw -short -class memory
H/W path Device Class Description
====================================================
/0/0 memory 128KiB BIOS
/0/3/a memory 128KiB L1 cache
/0/3/b memory 1MiB L2 cache
/0/11 memory 3GiB System Memory
/0/11/0 memory 512MiB DIMM DDR2 667 MHz (1.5 ns)
/0/11/1 memory 1GiB DIMM DDR2 667 MHz (1.5 ns)
/0/11/2 memory 1GiB DIMM DDR2 667 MHz (1.5 ns)
/0/11/3 memory 512MiB DIMM DDR2 667 MHz (1.5 ns)
/0/4/0 memory 128KiB L1 cache
/0/4/1 memory 1MiB L2 cache
/0/a memory RAM memory
/0/1.2 memory RAM memory
Above is my workstation which actually provides some indication
that it is a physical machine. How? Take a look:
/0/11 memory 3GiB System Memory
/0/11/0 memory 512MiB DIMM DDR2 667 MHz (1.5 ns)
/0/11/1 memory 1GiB DIMM DDR2 667 MHz (1.5 ns)
/0/11/2 memory 1GiB DIMM DDR2 667 MHz (1.5 ns)
/0/11/3 memory 512MiB DIMM DDR2 667 MHz (1.5 ns)
Device /0/11 is the systems PC5300 memory bank.
Device /0/11/0 is the first memory module in the bank and so on.
We can actually derive abit more information from above.This System
highly like has 2 CPU's or is a dual-core system:
First CPU's L1/L2 Cache:
/0/3/a memory 128KiB L1 cache
/0/3/b memory 1MiB L2 cache
Second CPU's L1/L2 Cache:
/0/4/0 memory 128KiB L1 cache
/0/4/1 memory 1MiB L2 cache
Of course we have BIOS:
/0/0 memory 128KiB BIOS
Some Misc Memory controls for the chipset:
/0/a memory RAM memory
/0/1.2 memory RAM memory
Thursday, July 29, 2010
Free 50GB of storage online
I was surfing around and found : https://www.adrive.com/login/signup
The Basic plan gives you 50GB of free storage. Thats CRAZY!
The Basic plan gives you 50GB of free storage. Thats CRAZY!
Wednesday, July 28, 2010
Pidgin: Facebook Plugin
Today I just happened to have stumbled upon this plugin for Pidgin. Its a plugin that allows you to chat with facebook friends :D Woot!
http://code.google.com/p/pidgin-facebookchat/
http://code.google.com/p/pidgin-facebookchat/
Linux: How to tell if you are Link UP
I was reviewing some of the most common interview questions asked to Linux Systems Administrators. I saw a great one:
Q. "How can you tell if an interface is link up?"
A. I guessed the old fashion one:
$>ifconfig eth0
Q. "How can you tell if an interface is link up?"
A. I guessed the old fashion one:
$>ifconfig eth0
Alternative answers:
$>ethtool eth0
Settings for eth0:
Supported ports: [ MII ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Supports auto-negotiation: Yes
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Advertised auto-negotiation: Yes
Speed: 100Mb/s
Duplex: Full
Port: MII
PHYAD: 1
Transceiver: external
Auto-negotiation: on
Supports Wake-on: g
Wake-on: d
Link detected: yes
*Interesting enough ethtool provides us some more key info see color code below for more details:
Current Duplex rate of device: [#]
Current Speed of device: [#]
$>ip link show
1: lo: loopback,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
link>loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eth0: broadcast,multicast,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN qlen 1000
link>ether 00:1e:8c:6e:e0:4f brd ff:ff:ff:ff:ff:ff
4: vboxnet0: broadcast,multicast\>mtu 1500 qdisc noop state DOWN qlen 1000
link>ether 0a:00:27:00:00:00 brd ff:ff:ff:ff:ff:ff
$> dmesg grep eth
[ 0.238932] ACPI Error (psparse-0537): Method parse/execution failed [\_SB_.MEM_._CRS] (Node f7019b70), AE_AML_BUFFER_LIMIT
[ 0.238957] ACPI Error (uteval-0256): Method execution failed [\_SB_.MEM_._CRS] (Node f7019b70), AE_AML_BUFFER_LIMIT
[ 2.230873] forcedeth: Reverse Engineered nForce ethernet driver. Version 0.64.
[ 2.231181] forcedeth 0000:00:07.0: PCI INT A -> Link[APCH] -> GSI 23 (level, low) -> IRQ 23
[ 2.231185] forcedeth 0000:00:07.0: setting latency timer to 64
[ 2.748879] forcedeth 0000:00:07.0: ifname eth0, PHY OUI 0x732 @ 1, addr 00:1e:8c:6e:e0:4f
[ 2.748883] forcedeth 0000:00:07.0: highdma pwrctl mgmt lnktim msi desc-v3
[ 13.217598] forcedeth 0000:00:07.0: irq 26 for MSI/MSI-X
[ 805.825023] device eth0 entered promiscuous mode
**** Note this last case will tell you if link fluxes happen.
Monday, July 26, 2010
Migrating from virtualbox-3.0 to virtualbox-3.2
I tend to have the attitude of... "If its not broken, dont fix it.
Well today after some testing over the last few weeks on a few other
systems I migrated virtualbox-3.0 to virtualbox-3.2 on my PC.
Just a small primer on how i did it:
$> sudo wget http://download.virtualbox.org/virtualbox/3.2.6/virtualbox-3.2_3.2.6-63112~Ubuntu~karmic_i386.deb
$> sudo apt-get remove virtualbox-3.0
$> sudo dpkg --install virtualbox-3.2_3.2.6-63112~Ubuntu~karmic_i386.deb
$> sudo echo "deb http://download.virtualbox.org/virtualbox/debian karmic non-free" >> /etc/apt/sources.list
$> sudo wget http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc
$> sudo apt-key add oracle_vbox.asc
$> sudo apt-get update
Enjoy!
Well today after some testing over the last few weeks on a few other
systems I migrated virtualbox-3.0 to virtualbox-3.2 on my PC.
Just a small primer on how i did it:
$> sudo wget http://download.virtualbox.org/virtualbox/3.2.6/virtualbox-3.2_3.2.6-63112~Ubuntu~karmic_i386.deb
$> sudo apt-get remove virtualbox-3.0
$> sudo dpkg --install virtualbox-3.2_3.2.6-63112~Ubuntu~karmic_i386.deb
$> sudo echo "deb http://download.virtualbox.org/virtualbox/debian karmic non-free" >> /etc/apt/sources.list
$> sudo wget http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc
$> sudo apt-key add oracle_vbox.asc
$> sudo apt-get update
Enjoy!
wget: Rate limiting Downloads
Nifty little feature i've ran across recently in wget:
wget http://mysqltuner.pl/ --limit-rate=5K
Essentially what this will do is.
1) "Wget http://mysqltuner.pl/" get the contents of mysqltuner.pl website
2) "--limit-rate=5K" limit the download rate to 5K ( equivalent of 56K modem. )
wget http://mysqltuner.pl/ --limit-rate=5K
Essentially what this will do is.
1) "Wget http://mysqltuner.pl/" get the contents of mysqltuner.pl website
2) "--limit-rate=5K" limit the download rate to 5K ( equivalent of 56K modem. )
Building a PC for under 200$
When I was in High School, mind you - I graduated in 2003, a computer for 200$ was far far away. You could get a name-brand CD burner for 200$ but that was about it. I think 500$ at that time was pretty reasonable for a P III 500mhz up to maybe P4 2GHZ the whole span of those 4 years.
Gaming Rigs at those times were 1K-4K depending on how cutting edge you wanted to go. The lower end gaming rigs at that time were around 800-900$ mids were in the 900$-1000$ range.
Over the last 7 almost 8 years since I've graduated I've built rigs for people on and off that have been consistently going down in price. I've actually priced out some low-end gaming rigs for around 300$, not including Monitor/keyboard/mouse.
I find mid-level gaming rigs to reach from about 400-700$ and High End still 800$+.
Systems that do not need this kind of speed and such are easily in the 200$ range.
I found this link today and thought I would share it with you :)
http://www.extremetech.com/
Gaming Rigs at those times were 1K-4K depending on how cutting edge you wanted to go. The lower end gaming rigs at that time were around 800-900$ mids were in the 900$-1000$ range.
Over the last 7 almost 8 years since I've graduated I've built rigs for people on and off that have been consistently going down in price. I've actually priced out some low-end gaming rigs for around 300$, not including Monitor/keyboard/mouse.
I find mid-level gaming rigs to reach from about 400-700$ and High End still 800$+.
Systems that do not need this kind of speed and such are easily in the 200$ range.
I found this link today and thought I would share it with you :)
http://www.extremetech.com/
Labels:
class of '03,
computers,
desktop,
discount,
good ol days,
inexpensive,
PC,
workstation
Tuesday, July 6, 2010
Debian: Bandwidth limiting apt
I enjoy tools like yum and apt, but wheres the control for limited bandwidth or shared bandwidth environments. Its not a magic options... or is it?
Example:
$> sudo apt-get -o Acquire::http::Dl-Limit=25 upgrade
Limits downloads to 25k. However how do i do this with a distro upgrade via cli?
sudo aptitude update &&
sudo aptitude -o Acquire::http::Dl-Limit=25 safe-upgrade &&
sudo aptitude -o Acquire::http::Dl-Limit=25 full-upgrade
Should set you at a pretty steady 25K upgrade process.. might take a couple hours but its worth it.
Example:
$> sudo apt-get -o Acquire::http::Dl-Limit=25 upgrade
Limits downloads to 25k. However how do i do this with a distro upgrade via cli?
sudo aptitude update &&
sudo aptitude -o Acquire::http::Dl-Limit=25 safe-upgrade &&
sudo aptitude -o Acquire::http::Dl-Limit=25 full-upgrade
Should set you at a pretty steady 25K upgrade process.. might take a couple hours but its worth it.
Subscribe to:
Posts (Atom)
