Archive for the ‘Debian’ Category

Change screen resolution by editing xorg.conf

Wednesday, July 25th, 2007

Ref:
http://www.linuxquestions.org/questions/showthread.php?t=331153

Most common solution, assuming you’re using the right driver, etc., is this one, which I copied from one of many threads here that lay it out.

vim /etc/X11/XF86Config-4

Find the section that looks like this:


Section "Screen"
Identifier "Default Screen"
Device "NVIDIA Corporation NV18 [GeForce4 MX - nForce GPU]”
Monitor “Generic Monitor”
DefaultDepth 24
SubSection “Display”
Depth 1
Modes “800×600″ “640×480″
EndSubSection
SubSection “Display”
Depth 4
Modes “800×600″ “640×480″
EndSubSection
SubSection “Display”
Depth 8
Modes “800×600″ “640×480″
EndSubSection
SubSection “Display”
Depth 15
Modes “800×600″ “640×480″
EndSubSection
SubSection “Display”
Depth 16
Modes “800×600″ “640×480″
EndSubSection
SubSection “Display”
Depth 24
Modes “800×600″ “640×480″
EndSubSection
EndSection

and make it look like this:


Section "Screen"
Identifier "Default Screen"
Device "NVIDIA Corporation NV18 [GeForce4 MX - nForce GPU]”
Monitor “Generic Monitor”
DefaultDepth 24
SubSection “Display”
Depth 1
Modes “1024×768″ “800×600″ “640×480″
EndSubSection
SubSection “Display”
Depth 4
Modes “1024×768″ “800×600″ “640×480″
EndSubSection
SubSection “Display”
Depth 8
Modes “1024×768″ “800×600″ “640×480″
EndSubSection
SubSection “Display”
Depth 15
Modes “1024×768″ “800×600″ “640×480″
EndSubSection
SubSection “Display”
Depth 16
Modes “1024×768″ “800×600″ “640×480″
EndSubSection
SubSection “Display”
Depth 24
Modes “1024×768″ “800×600″ “640×480″
EndSubSection
EndSection

Debian sources.list file contents

Tuesday, July 3rd, 2007

Ref:
http://www.mayin.org/ajayshah/COMPUTING/debian-principles.html

The sources.list for using stable reads —
# See sources.list(5) for more information
deb http://http.us.debian.org/debian stable main contrib non-free
deb http://non-us.debian.org/debian-non-US stable/non-US main contrib non-free
deb http://security.debian.org stable/updates main contrib non-free

security.debian.org is only relevant for stable since the core stable is supposed to be constant. With the other distributions, security updates are just normal package updates.

As the comment points out, you can say man 5 sources.list to learn the file format.

How to install kernel headers in Linux?

Tuesday, July 3rd, 2007

Ref: http://ubuntuforums.org/archive/index.php/t-25258.html

Install the headers for the release of the kernel you have installed. To find this out you can type
uname -r

To get the header you can apt-get install them,

sudo apt-get install linux-headers-`uname -r`

Debian Resources

Monday, October 24th, 2005

AboutDebian:
http://www.aboutdebian.com/linux.htm

AboutDebian - Installing Debian
http://www.aboutdebian.com/install31.htm

Juerd.nl: Nice site, with perl tips, etc
http://juerd.nl/site.plp/debianraid

Debian APT Basic Commands
http://www.linuxgazette.com/issue84/tougher.html

Setup a Database server using Debian
http://www.aboutdebian.com/database.htm

The Perfect Setup - Debian
http://www.projektfarm.com/en/support/debian_setup/

Debian: Check runlevel

Friday, October 21st, 2005

cat /etc/inittab | more

Search for: default runlevel

Look for a line like this:
id:2:initdefault:

Debian: Configuring X

Monday, April 11th, 2005

commands:
dexconf - Stands for Debian X Configuration Tool
dpkg-reconfigure xserver-xfree86

Debian: Configuring the time and timezone

Monday, April 11th, 2005

While doing an upgrade from woody to sarge (by adding a new source to the /etc/apt/sources.list),
the install process showed me the current time (which was an hr behind) and asked me to run
tzconfig in order to configure the time.

Debian: Configuring the network

Sunday, April 10th, 2005

After configuring the module (as explained in the prev post), it is time to configure the card.
I found this great link explaining the Debian install (complete with screenshots)

Since I am on DHCP, I just edited the /etc/network/interfaces file and added this:

auto eth0iface eth0 inet static

Then, I restarted the network:
/etc/init.d/networking restart

A quick ifconfig showed that the IP had been acquired.
A ping took about 2-3 secs before it responded, but it was all OK!

netstat -r showed the routing table. The gateway was set and so was I !!!

Configure modules in Debian

Sunday, April 10th, 2005

After unsuccessfully trying to install FreeBSD 5.2/5.3 on the P-133Mhz,
I installed Debian. But during the install process, I could not detect the network card in the modules list and skipped selecting any driver.

After the install, I spent a good amount of time trying to get the same configuration screen.
I had used lspci or something to get the name and model number of the card.
So now I wanted to go and install the relevant drivers (if they were there).

Linksys LNE100TX (Linksys EtherFast 10/100)
For some reason, this was also shown: Lite-On Communications Inc.
IRQ 10, I/O ports at fc100.

The command, you have all been waiting for, is: modconf (thunderous applause).

The installer, when I entered the network configuration (the IP addr, etc), showed the interface as Intel-something. Probably was showing me what the compatible chipset or something was.

The Linksys website shows that the tulip driver is the driver for this card.

Update: Using the tulip driver in modconf installed the card successfully.
Now need to go and configure the card.

.vimrc options to assist with perl coding

Sunday, January 16th, 2005

Edit the .vimrc file and add the following:





” F2 close current window (commonly used with my F1/F3 functions)

noremap :close

” perl -cw buffer, using a temp file, into a new window

function! PerlCW()

let l:tmpfile1 = tempname()

let l:tmpfile2 = tempname()

execute “normal:w!” . l:tmpfile1 . “\

execute “normal:! perl -cw “.l:tmpfile1.” \> “.l:tmpfile2.” 2\>\&1

+ \

execute “normal:new\

execute “normal:edit ” . l:tmpfile2 . “\

endfunction

” perl buffer, using a temp file, into a new window

function! PerlOutput()

let l:tmpfile1 = tempname()

let l:tmpfile2 = tempname()

execute “normal:w!” . l:tmpfile1 . “\

execute “normal:! perl “.l:tmpfile1.” \> “.l:tmpfile2.” 2\>\&1 \
+R>”

execute “normal:new\

execute “normal:edit ” . l:tmpfile2 . “\

endfunction

” Settings for editing perl source (plus bind the above two functions)

function! MyPerlSettings()

if !did_filetype()

set filetype=perl

endif

set textwidth=78

set expandtab

set tabstop=4

set shiftwidth=4

set cindent

set comments=:#

set formatoptions=croql

set keywordprg=man\ -S\ 3

noremap :call PerlCW()

noremap :call PerlOutput()

endfunction

if has(”eval”)

augroup SetEditOpts

au!

autocmd FileType perl :call MyPerlSettings()

augroup END

endif

endif