Best of Technical Support
I have installed ntpd on Red Hat 8, and it runs but does not appear to do anything. The log file indicates it is starting up, but after a few minutes, it displays the following message:
kernel time discipline status change 41
After that, nothing else is written to the log file. What does the
kernel time discipline message mean? How can I tell if ntp actually is
updating my system clock? If it isn't doing updates, how can I get
it to work properly?
To check if ntpd, the Network Time Protocol dæmon,
is working correctly, type ntptrace localhost
to see where your system is getting its time and
where its upstream time server is getting its time.
To be polite, don't set up ntpd to use a heavily
loaded public time server—your ISP or local
Linux user group should be able to give you access
to a server that is close to you.
Here are a few things to check. First, ntpd will not synchronize time
differences greater than one hour, so use ntpdate first to get your
clock in range. Second, make sure you have not configured ntpd to
use multicast/broadcast client functionality unless you have a time
server on your local network. Third, if you are running a recent
version of ntp make sure you have a restrict parameter in your
configuration file for each time server you use, as newer versions
are much more security-aware. Finally, use the ntpq tool and the
assoc command to verify that ntpd is running properly.
My wife's computer is inside a LAN and accesses the Internet through
a proxy (no other connections are allowed, only WWW). As we are working
on a common project, I need her to connect to some of our internal sites
that are accessible only through another proxy.
The situation is this:
my wife's computer→proxy1→Internet→proxy2→internal sites.
In that scheme, I have full control on proxy2 (a Debian box running squid).
Any ideas about how to do this?
Mauro A. Cremonini
If you are running the Squid proxy, cache_peer and other settings
allow you to daisy-chain proxy servers together. You need to establish
a cache_host entry that defines the internal sites as described above
and a dstdomain ACL entry for the internal sites that forces them to
be accessed through proxy2. Squid is a powerful proxy server, and you can slice and dice your
traffic management a number of different ways. For more tips and
tricks, see the Squid FAQ at www.squid-cache.org/Doc/FAQ/FAQ.html.
If you aren't running a Web server on proxy2's port 80, you can run rinetd to forward connections from it to a system on your internal network (www.boutell.com/rinetd). For security, though, the best thing would be to ask your wife's network administrator to open up their firewall for outgoing SSH. Then, give her a shell account on proxy2 so that she can tunnel in with the following:
ssh -N -L 8080:internal:80 proxy2
Here's an explanation of the ssh command-line options above: -N, don't start a shell; -L, forward a local port; 8080, port on which to accept connections on localhost; internal, host to which to forward connections; 80, port to which to forward connections; and proxy2, host to which to make the SSH connection.
Then, she simply can point her browser at
localhost:8080 and get to your internal server,
and you don't have to open up anything except
incoming SSH to your proxy.
I'm trying to port some Windows applications to Linux (Red Hat 7.3
and 9), and I need to find a replacement method for my current printing
mechanism. The current printing process goes like this:
1) The application opens LPT8: for write as a file. LPT8: is a Windows
device, not a real physical port. Data (plain ASCII text) is written to
the device. When done, the device is closed.
2) LPT8: is captured by a Novell Netware capture program so that
anything written to LPT8: winds up in a Novell Netware printer queue.
3) The Novell Netware server sends the data to a barcode printer. The
printer is attached to the network using one of those little AXIS
print servers that can handle multiple protocols including Novell
NPRINTER and lpd.
I want to know if there is any way to keep the basic operation of
the program the same: open a file/device, write to it, close it.
Everything else that needs to happen occurs in the background.
I can see doing this using calls to external programs: create a temp
file with the data, then pass the file to a printing program like lpr.
This is a bit more complicated but will work if the first method doesn't.
Or, one could create a temp file and put a watch on the temp directory
to grab any files there. The user expects near instantaneous response,
The Novell Netware server is going to be replaced by a Linux box
eventually. The Windows machines will use Samba for their printers. I
haven't decided on which printing system to use yet, probably CUPS.
The programs are written in Delphi/Kylix Object Pascal. Any hints on
where I should start looking?
This can be easy or difficult depending on what you are willing to do. The
solution you referenced above that involves the creation of a temporary
file actually is the easiest solution. You can use the tmpnam() function
to obtain a unique filename to ensure your process won't conflict with
any others. This concept keeps you within the open-file, write-file,
close-file work flow you described above, and you shouldn't require an
external program to do this work.
If your program was structured such that it always
created a temporary file and called out to a
configurable command, it would remain portable. On
a Windows box one could use a copy command to
dump the file to LPT8:, and on a Linux box one could
use the lpr command. This would make your program
I installed Red Hat 9 on a Dell Inspiron 1100 laptop. It
appears that no power-management support was installed (this is an ACPI
machine, not APM). A few Web sites have reported success with this
system, except for ACPI.
I tend to stick with Red Hat standard releases because I rely on my
laptop for everyday use (I use it 6–8 hours a day for teaching). I
experiment on my working system.
What is the impact of not including ACPI support? Do I run the risk of
damaging the CPU without it, or can I live without it (at least for a
while)? Can you point me to a how-to about ACPI and Linux?
Running with ACPI enabled will not harm your system unless you are
overclocking or doing some other activity that relies on the alerts ACPI
would provide. In a laptop environment this is extremely unlikely.
However, you may not see the same battery lifetimes without ACPI, because
that is the same module used to identify whether the system is running on
AC or battery, to scale the speed of the CPU and so forth.
For more information on ACPI, consult the ACPI-HOWTO in the Linux
Documentation Project (LDP): www.ibiblio.org/pub/Linux/docs/HOWTO/other-formats/html_single/ACPI-HOWTO.html.
|Designing Electronics with Linux||May 22, 2013|
|Dynamic DNS—an Object Lesson in Problem Solving||May 21, 2013|
|Using Salt Stack and Vagrant for Drupal Development||May 20, 2013|
|Making Linux and Android Get Along (It's Not as Hard as It Sounds)||May 16, 2013|
|Drupal Is a Framework: Why Everyone Needs to Understand This||May 15, 2013|
|Home, My Backup Data Center||May 13, 2013|
- RSS Feeds
- Dynamic DNS—an Object Lesson in Problem Solving
- Making Linux and Android Get Along (It's Not as Hard as It Sounds)
- Designing Electronics with Linux
- Using Salt Stack and Vagrant for Drupal Development
- New Products
- A Topic for Discussion - Open Source Feature-Richness?
- Drupal Is a Framework: Why Everyone Needs to Understand This
- Validate an E-Mail Address with PHP, the Right Way
- What's the tweeting protocol?
3 min 9 sec ago
- Kernel Problem
10 hours 5 min ago
- BASH script to log IPs on public web server
14 hours 32 min ago
18 hours 8 min ago
- Reply to comment | Linux Journal
18 hours 41 min ago
- All the articles you talked
21 hours 4 min ago
- All the articles you talked
21 hours 7 min ago
- All the articles you talked
21 hours 9 min ago
1 day 1 hour ago
- Keeping track of IP address
1 day 3 hours ago
Enter to Win an Adafruit Pi Cobbler Breakout Kit for Raspberry Pi
It's Raspberry Pi month at Linux Journal. Each week in May, Adafruit will be giving away a Pi-related prize to a lucky, randomly drawn LJ reader. Winners will be announced weekly.
Fill out the fields below to enter to win this week's prize-- a Pi Cobbler Breakout Kit for Raspberry Pi.
Congratulations to our winners so far:
- 5-8-13, Pi Starter Pack: Jack Davis
- 5-15-13, Pi Model B 512MB RAM: Patrick Dunn
- 5-21-13, Prototyping Pi Plate Kit: Philip Kirby
- Next winner announced on 5-27-13!
Free Webinar: Hadoop
How to Build an Optimal Hadoop Cluster to Store and Maintain Unlimited Amounts of Data Using Microservers
Realizing the promise of Apache® Hadoop® requires the effective deployment of compute, memory, storage and networking to achieve optimal results. With its flexibility and multitude of options, it is easy to over or under provision the server infrastructure, resulting in poor performance and high TCO. Join us for an in depth, technical discussion with industry experts from leading Hadoop and server companies who will provide insights into the key considerations for designing and deploying an optimal Hadoop cluster.
Some of key questions to be discussed are:
- What is the “typical” Hadoop cluster and what should be installed on the different machine types?
- Why should you consider the typical workload patterns when making your hardware decisions?
- Are all microservers created equal for Hadoop deployments?
- How do I plan for expansion if I require more compute, memory, storage or networking?