Best of Tech Support

Our experts answer your technical questions.
I Have No “core” and I Must Debug

The default action for a dozen UNIX signals like SIGSEGV is to abort and generate a core file as a dump of the memory image of the faulty process. On Red Hat, when getting such signals, the processes abort but do not generate any core file. The only way to know a faulty process was sent such signals is to strace it. If it is possible, where on Red Hat is the core generation configured?

—Pedro Guedes, pmg01@netc.pt

The ulimit command controls the size limit of several things in your Linux system, among them, the size of the core files. Issuing a ulimit -c 0 will tell Linux to disable core files (since they will be of zero size), ulimit -c xxxx will tell Linux to allow core files of up to xxxx blocks in size. ulimit may be set in /etc/profile for all users or in your home directory's .bash_profile. Typing ulimit -h gives help on this command. If you edit the file /etc/security/limits.conf, there you may find a line something like:

*  soft   core  0

or:

*  hard   core  0

That last 0 on each of these examples indicates that the core file size should be no bigger than 0KB; therefore there are no core files generated. Hard and soft refer to the kind of limit imposed, “hard” being more strict. Change that 0 to something else, depending on the biggest core dump file that you may expect. This file (/etc/security/limits.conf) is part of the PAM (Pluggable Authentication Modules) system, which most distributions, including Red Hat, use.

—Felipe E. Barousse Boué, fbarousse@piensa.com

X on an Old SiS Video Card

I have installed Red Hat 7.2 on an old (1994-ish) colussus, but I cannot get X to run as it doesn't see the monitor, which is a CTX 1565CD. However, when I try to run Xconfigurator or any other X config tool, it does not pass the X config test. When started, the PCI probe returns the entry Silicon Integrated Systems (SiS) SG86C20, which does not appear anywhere on the list of supported cards.

—Jim Logan, jim_message@hotmail.com

The Linux Hardware Compatibility Guide (www.ssc.com/mirrors/LDP/HOWTO/Hardware-HOWTO) says you can use XF86_SVGA in a 3.x version of XFree86, or the “sis” driver in a 4.x version. The SVGA driver is a good option to try because it works with almost any card, although it will not be accelerated. Also, if you have a newer version of X, see if your card supports VESA by enabling it in the kernel and using the “vesa” driver for X.

—Chad Robinson, crobinson@rfgonline.com

What's My IP Address Today?

I have Cox.net broadband service with an SMC router yielding a DHCP address for my home network. On the network, a Linux box is the virtual server. What I would like to do is poll the router to find the LAN side address and e-mail it to myself. The purpose of course is to be able to remotely connect using the DHCP IP address. The web page configuration on the router always starts at the login page regardless of the URL used (security). SMC does not seem willing to respond at all to my question.

—Tom Mautner, mautner@cox.net

Have you considered a dynamic DNS service? That may let you do an end run around to collect the address internally. A service such as ZoneEdit will allow you to update your address automatically via a web query, which you can automate with lynx.

—Chad Robinson, crobinson@rfgonline.com

Send yourself an empty e-mail, and you will see that the Received header lines will contain the IP that your router used when it connected to Cox's mail relay. You'll see something like this:

Received: from manyroads.ssc.com (manyroads.ssc.com
        [192.168.3.58]) by mail.ssc.com (Postfix) with ESMTP

and you can get the IP from there. Not high tech, but it works.

—Marc Merlin, marc@merlins.org

If the router is doing NAT, and you want the address of its internal interface, run:

route -n | mail you@example.net

—Don Marti, dmarti@ssc.com

X Takes over Both Video Cards

I have two graphic cards in my box, one is ATI Rage XL (PCI) and one is ATI RADEON VE QY (AGP). I would like to control the AGP card from a kernel module we have written (which displays on a projector), and I would like to let X control the PCI card (which displays on a flat panel monitor). The problem begins when we use startx. The PCI controlled monitor starts X correctly, but our kernel module no longer has control of our AGP card (no image displays on the projector). Does anyone know why X seems to be taking away our control of the AGP card?

—Jing Xu, jing@cs.unm.edu

Try forcing X to use a specific bus ID using the “BusID” parameter. Perhaps X is trying to use both cards as a multihead configuration, but you should be able to prevent it from doing that.

—Chad Robinson, crobinson@rfgonline.com

______________________

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

mount usb

Anonymous's picture

simply type: mount /dev/sda1 /somewhere

Re: Best of Tech Support

Anonymous's picture

Here is a script (sanitized) that I use to post my IP address. You can easily modify it to send an email instead of uploading a web page. Then just add it to your crontab to run as often as you want. Here's the URL where you can see the results of the script: http://home.hawaii.rr.com/nelsongarcia/myip.html

Aloha,

Nelson Garcia

#!/usr/bin/expect -f

set ftpserver "yourftpserver.com";

set username "yourusername";

set userpass "yourpassword";

set tmpfile "/tmp/myip";

set pubfile "myip.html";

set ifconf "/sbin/ifconfig";

set ip [exec $ifconf eth0]

set indx [string first "inet addr" $ip]

set indx [expr $indx +10]

set ip [string range $ip $indx end]

set indx [string first " " $ip]

set indx [expr $indx -1]

set ip [string range $ip 0 $indx]

set systime [clock seconds]

set datestrng "Last updated: [clock format $systime -format %H:%M:%S] - [clock format $systime -format {%B %d, %Y}]"

set toout [open "$tmpfile" w];

puts $toout "<html><head><title>My IP Address</title></head><body>";

puts $toout "<h1>My current IP is: <a href='http://$ip'>$ip</a><br>$datestrng </h1>";

puts $toout "<hr><h2>Warning</h2><br>Please do not bookmark any pages on my home server using the IP address as it is subject to change.";

puts $toout "<br>If the time above appears old, it probably means that my server is down and that you should not follow the link.";

puts $toout "<br><hr>Mail comments to <a href='mailto: '>Me</a>.</body></html>";

close $toout;

spawn ftp "$ftpserver"

expect "Name*:"

send "$username\r"

expect "Password:"

send "$userpass\r"

expect "ftp>"

send "put $tmpfile $pubfile\r"

expect "ftp>"

send "quit\r"

close

puts "\n"

White Paper
Linux Management with Red Hat Satellite: Measuring Business Impact and ROI

Linux has become a key foundation for supporting today's rapidly growing IT environments. Linux is being used to deploy business applications and databases, trading on its reputation as a low-cost operating environment. For many IT organizations, Linux is a mainstay for deploying Web servers and has evolved from handling basic file, print, and utility workloads to running mission-critical applications and databases, physically, virtually, and in the cloud. As Linux grows in importance in terms of value to the business, managing Linux environments to high standards of service quality — availability, security, and performance — becomes an essential requirement for business success.

Learn More

Sponsored by Red Hat

White Paper
Private PaaS for the Agile Enterprise

If you already use virtualized infrastructure, you are well on your way to leveraging the power of the cloud. Virtualization offers the promise of limitless resources, but how do you manage that scalability when your DevOps team doesn’t scale? In today’s hypercompetitive markets, fast results can make a difference between leading the pack vs. obsolescence. Organizations need more benefits from cloud computing than just raw resources. They need agility, flexibility, convenience, ROI, and control.

Stackato private Platform-as-a-Service technology from ActiveState extends your private cloud infrastructure by creating a private PaaS to provide on-demand availability, flexibility, control, and ultimately, faster time-to-market for your enterprise.

Learn More

Sponsored by ActiveState