Cooking with Linux—The French Connection
Allo, and welcome to Chez Marcel, home of fine French Linux cooking.
Please take a seat. If you have not already done so, I would like you to read this article with a somewhat exaggerated French accent since that is the way I wrote it. Even the README files are heavily accented. For those of you who, like myself, are French, you may translate as you read, thus adding another level of authenticity to the excellent menu that awaits you.
It is an honour and a privilege to welcome you to my kitchen. Tonight, I have a special treat for you. The recipes I have prepared are made from common Linux distribution ingredients so that you can recreate these delicacies when you return to your own kitchen CPU. Tonight's menu:
Mail notification for Windows clients
What's my IP?
Waiter! More disk.
Waiter! There's a fly in my system.
Is it That Time Already?
I must tell you right now that I am thrilled you have decided to join me in my kitchen. Much of what I have in store for you is designed to make Windows 9x more productive with a little help from Linux. If you have already cast away your Windows PC but you miss some forgotten piece of software (provided that software is not too demanding), you could check out http://www.winehq.com/ for the latest version of the Windows non-emulator for Linux.
For many users out there, the Windows workstation is still on the desktop, while the Linux machine performs such noble tasks for the Windows user as connecting to the Internet, providing firewall services, delivering mail, sharing disk space and printers, among other services.
What we have in store for you here today are Linux scripts that can make your Windows experience more enjoyable.
In the next few examples, we will have our Linux system talk back to Windows. While that is a good idea, we must first set up Windows to listen; otherwise, all our talk will disappear into the proverbial ether. When our Linux system needs to contact a Windows user, it will do so using Samba's smbclient messaging functionality. Obviously, that requires a system running Samba. On the Windows side, it requires Winpopup.
To set up Winpopup to start each time you boot Windows, create a shortcut in the Windows Startup folder. Click on the Start button, then Settings, then Taskbar. Choose the tab that says “Start Menu Programs”, then click the Advanced button. This will open a Windows Explorer window. Open the Startup folder under Programs and add a shortcut to winpopup.exe. Accept the default name, and you will wind up with a cute little Jack-in-the-box icon. Right-click on it to access the properties tab. Now, set the Run: option to Minimized. Winpopup starts up out of the way, and pops up only when it gets a message. Double-click the icon to start it right away.
One more thing: you should now see Winpopup sitting minimized on your taskbar. Click on it to bring it up. Now click on Messages, and choose Options from the drop-down menu. Click the box for “Pop up dialog on message receipt”. Click OK and re-minimize Winpopup. Windows is now ready to receive messages from your Linux system, which brings us to the next item on the menu.
This is a frequent question we get from users. You are the administrator of a small- to medium-size office; you've set up an Internet gateway that picks up the mail on a regular basis using fetchmail, which then stores it on your Linux server. The problem is that your users are still running Windows with some sort of stand-alone POP3 e-mail package like David Harris' Pegasus Mail. While many packages can be set up to retrieve mail automatically, keeping them open and running taxes their already taxed Windows system. This means users tend to point out how slowly their systems are running. You suggest they close a few applications. “How about e-mail?” you suggest. To which they reply, “What if I miss an important message?” The solution is the checkusermail script shown in Listing 1.
In /usr/local/etc, create a small text file called mail_notify with the names of users who receive mail on your system. If the Windows clients are named differently (in the network configurator of the Windows control panel) than the user ID for mail, create an /etc/lmhosts file with IP addresses matching your mail user IDs, and the results should be the same. The script can be run from cron at whatever time interval suits your environment. Since it runs as root, it can spy into everyone's mailbox with the frm command. It will tell each user they have mail and how many messages. If there is no mail, there is no message and no need to waste time and energy checking every few minutes.
Another happy soul you'll discover after you deploy this script is the boss who had been complaining about either the amount of time users spent checking mail, or the user who did not check it often enough and missed an important message.
|Free Today: September Issue of Linux Journal (Retail value: $5.99)||Sep 27, 2016|
|nginx||Sep 27, 2016|
|Epiq Solutions' Sidekiq M.2||Sep 26, 2016|
|Nativ Disc||Sep 23, 2016|
|Android Browser Security--What You Haven't Been Told||Sep 22, 2016|
|The Many Paths to a Solution||Sep 21, 2016|
- Free Today: September Issue of Linux Journal (Retail value: $5.99)
- Android Browser Security--What You Haven't Been Told
- Readers' Choice Awards 2013
- Epiq Solutions' Sidekiq M.2
- The Many Paths to a Solution
- Nativ Disc
- Download "Linux Management with Red Hat Satellite: Measuring Business Impact and ROI"
- Synopsys' Coverity
- Tech Tip: Really Simple HTTP Server with Python
Pick up any e-commerce web or mobile app today, and you’ll be holding a mashup of interconnected applications and services from a variety of different providers. For instance, when you connect to Amazon’s e-commerce app, cookies, tags and pixels that are monitored by solutions like Exact Target, BazaarVoice, Bing, Shopzilla, Liveramp and Google Tag Manager track every action you take. You’re presented with special offers and coupons based on your viewing and buying patterns. If you find something you want for your birthday, a third party manages your wish list, which you can share through multiple social- media outlets or email to a friend. When you select something to buy, you find yourself presented with similar items as kind suggestions. And when you finally check out, you’re offered the ability to pay with promo codes, gifts cards, PayPal or a variety of credit cards.Get the Guide