How to delete all but one file in linux directory

ls *| grep -v FileName | xargs rm -rf

Using this command you can delete all files except the one listed.

List of IP Addresses by Country

Blocking IP Addresses by Country of origin is a time consuming task. If you use a cisco or checkpoint firewall or even PF firewall on your linux distribution the configuration of such a large list of IP addresses to Block is a fairly large task.

But if you’re up to the task head over to http://www.countryipblocks.net/tag/cidr/

Here you can list all IP addresses by Country and then add them to a blacklist of untrusted IP Addresses.

Or better yet allow those you trust and disallow everyone else.

Now you can block bad IP addresses based on Country but user beware, IP addresses are added often, you’ll want to keep it up-to-date at least once a month.

Show Content on WordPress Home and None Homepages

is_home – this only shows content on wordpress homepage Read more

How to Create a 336 ad block, adsense

In order to create a 336 ad block for fantasyknuckleheads.com Read more

Enable FTP FreeBSD and Allow Only Localhost

Enable FTP on your FreeBSD server and allow only your localhost (local machine) access to the ftpd server. Read more

Google Apps No Support for IE 6

Just got an email from the Google Apps team announcing that google apps will stop supporting IE 6 as well as other older browsers that are not supported by their own manufacturers. If you’re still using IE6 I’m sure your computer is infected with so many different forms of malware you can barely stand to wait for the system to respond. Never the less in case you missed the email here it is in its entirety. Read more

Best freeBSD Firewall for a Web Server, PF Configuration and Testing

freeBSD 8 firewall for web server

freeBSD 8 firewall for web server

You’ll see many articles discussing various firewalls for BSD. freeBSD comes with three firewalls but I’ll lay out what I believe is the best freebsd firewall for a web server, pf. Read more

How to shutdown freebsd 8 and stop shutdown

Shutdown freebsd now

shutdown -r now

Read more

FreeBSD 8 LAMP Install for WordPress

How to install FreeBSD 8 for WordPress. It’s a basic LAMP install but since we’re not using linux it should be called BAMP or maybe FAMP? Who cares.. here are the steps to install FreeBSD 8 with apache, mySQL, PHP then install wordpress.

I’ll be using ports of course for this entire install. I’m assuming that you have the proper hardware for this type installation.

Start with a minimal installation of freeBSD 8

Read more

Home HD 3D TV, Get Your Popcorn Ready

After watching the movie Avatar set the standard in 3D motion pictures I could not pass up writing a review for the new market buzz on 3D TV’s for your home.

Read more