Postgrey: reset periodically database

3 commenti » Debian , System , Tips & Tricks 3 Comments »

Who uses Postgrey as part of anti-SPAM complex must periodically reset the database that the application has generated. This is because by the time server many spammers are able to maintain long periods of operation without anything or anyone capable of stopping them - making them end up in one of the blacklist of reference, for example.

The result is that more and more servers spammers end up in some big database of the combinations considered by our trustable Postgrey, invalidandone facto effectiveness. To avoid scenarios like this there is a brutal but effective method: Postgery completely reset the database and its lock file, bringing it back to the original situation.

Here's how:

  1. stop the daemon Postgrey
  2. delete the directory / var / lib / postgrey (I highly recommend renaming)
  3. create a / var / lib / postgrey empty
  4. restart Postgrey

In other words, one must proceed as follows:

# /etc/init.d/postgrey stop
# cd /var/lib
# mv postgrey postgrey_OLD
# mkdir postgrey
# chown -R postgrey:postgrey postgrey
# /etc/init.d/postgrey start

These instructions are for Debian GNU / Linux - my reference distribution - but they work for almost all other available distributions. Contraindications? None, except that the reset mechanism will then be taken into consideration all new messages, even those from the actual server trustable - that already had their triplets in db Postgrey - causing minor delays in delivery of mail. For this advice to reset only a couple of times a year.

WordPress: delete all the posts of a category

Nessun commento » MySQL , Tips & Tricks , Wordpress No Comments »

This guy was found in my same situation and solved the problem before me in a simple and elegant, which is why I report on his article and I note here the valuable SQL string. It 's true that before doing anything else googolata is a must!

I fully agree with what he says about the limits of the plugin Bulk Delete : works only if the posts are removing a few hundred, unless you put out, raising his hand to the server Apache and reserving more RAM to process PHP - highly recommended choice , as a rule these are tuning in a more rational facts and not just to run a WordPress plugin.

Here the string, sempclie and immediate, to obtain the definitive cancellation of all the posts belonging to a specific category:

 
 delete a, b, c, d

 FROM wp_posts to

 Wp_term_relationships LEFT JOIN b ON (a.ID b.object_id =)

 Wp_postmeta LEFT JOIN c ON (a.ID c.post_id =)

 Wp_term_taxonomy LEFT JOIN d ON (d.term_taxonomy_id b.term_taxonomy_id =)

 LEFT JOIN and ON wp_terms (e.term_id d.term_id =)

 WHERE e.term_id = '12345 ' 

A quiet weekend of fear (Deliverance, 1972) and the legendary freak sequence of dueling banjos

Nessun commento » YouTube No Comments »

Dedicated to all those who were kids in the eighties and if they are seen and reviewed a dozen times on private television.

Consumption of banda: monitor with vnStat

1 commento » Beginners , Shell , System , Tips & Tricks 1 Comment »

Among the many applications available to control the bandwidth usage of a server there is one that davero does its job well: it is vnStat, a network traffic monitor for Linux and BSD systems. This application behaves in practice as a logger that keeps track of the volumes of data into and out drawing on information provided in real time directly from the kernel. Here are the main features of vnStat as ifficiale are presented on the website of the project:

  • quick and simple to install and get running
  • Gathered statistics Persists through system reboots
  • Can monitor multiple interfaces at the Same Time
  • Several output options
    • summary, hourly, daily, monthly, weekly, top 10 days
    • png image output option (using libgd)
  • months can be configured to follow the billing period
  • light, minimal resource usage
  • examination low cpu usage, regardless of traffic
  • can be used without root permissions
  • online editor color configuration

Its installation is very simple and immediate effects, especially on Debian-derived systems:

# aptitude install vnstat

Once the package is installed, you must initialize a database devoted to logging for each network adapter that you want to monitor. If you want to monitor the eth0 card, for example, is sufficient to run the command:

# vnstat -u -i eth0

Without this, to keep the monitored traffic on that specific network card is sufficient to run the program without any arguments:

ivan@biberon:~$ vnstat
Database updated: Fri Jun 24 01:00:01 2011
eth0
received: 4.71 GB (13.0%)
transmitted: 31.58 GB (87.0%)
total: 36.29 GB
rx | tx | total
-----------------------+------------+-----------
yesterday 1.74 GB | 11.92 GB | 13.66 GB
today 31.97 MB | 162.10 MB | 194.07 MB
-----------------------+------------+-----------
estimated 720 MB | 3.67 GB | 4.38 GB

And 'possible to generate different types of reports to the program by passing the required argument, but I already use the standard specified above may be more than sufficient for routine monitoring operations. More information can be found at these addresses:

  • http://humdi.net/vnstat/
  • http://www.debian-administration.org/articles/330

Silence theater is ringing the Silence Day 2011

Nessun commento » Announcements , News , Reports No Comments »

Is renewed each year as the date with the Silence Theatre , the historic loverese company that brings over twenty years around the world on their own very special theater visionary and sublime. Like every year the event includes performances and workshops. Guest star of this edition is certainly Ascanio Celestini , which will bring "The row Indian - racism is a bad story" on stage at the Crystal Theatre Lovere the evening of June 17 . Do not miss the workshop to be held Wednesday, June 15 from 20:30 to 23:00 at the offices of Silence Theatre in via Ranzinello, two in Costa Volpino. The workshop is open to all those who want to try a creative group. For information and registration please call these numbers: 035 983713 - 335 5605664.

For over twenty years experience in research work
through forms of expression in theater and
looking environment interaction between urban and
artistic proposal. Masks and white as angels
plaster statues, groups inspired by the compositions
famous paintings, immigrants and people with large suitcases
literature are integrated to the places of
everyday life, a startling stage extends
open spaces. Fear, resignation, joy, challenge,
love, abandonment, anger, confidence, hate, ecstasy:
through postures and tensions of the body, in a silent
language, the actors speak externalizing and eliciting
emotions that you stick to places and people.

Brian Eno - By This River

Nessun commento » Logbook , YouTube No Comments »

There is something joyful that is hidden in a piece so decidedly melancholy. Do not you think?

Make it stop, please ...

Nessun commento » Log book , Reflections (oni) No Comments »

While the fans of my laptop puffing hot air that smells of fried polymers, Nichi Vendola rattles off the repertoire of ready-made phrases to which we are accustomed. Not that I contexts priori his positions or that I have preconceptions about his person, annoys me just his way of communicating. People capable of speaking for over 90 minutes of any topic with the frown and that expression of the face seems to say that I am a serious person I've seen and heard them too. Usually are machines that replicate invariably the same rhetorical patterns, camuffandoli be well-formed thoughts. Just listen to them twice in two different contexts - for example a press conference and interview on some local TV - for realizing that replicates every time the same mechanics of facial expressions, pauses and accents horribly identical. When communication is a cheesy snack, what's inside the clear plastic is usually not worth much. Make it stop, please ...

Debian Squeeze: change the memory_limit parameter in / etc/php5/cli/php.ini

Nessun commento » Apache , Debian , PHP , Tips & Tricks No Comments »

On Debian Squeeze all there is to do a correction on the fly to php.ini dedicated to running server-side script (aka command line). The correction is of vital importance, but only if you put in cron php script and do not want the server refuses to run because they require more memory than can be allocated. The problem is due to the parameter:

memory_limit = -1

Since it would seem a flag disabled and then we would expect that there is no limit in the memory can be allocated, but the behavior is quite different:

PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 64 bytes) in /var/www/clients/client21/web54/web/XXXXXX.php on line 212

As a workaround, you should specify which actually is the limit of memory that we intend to impose a php script run from command line. The parameter is in the file:

/etc/php5/cli/php.ini

And the change to be made is as follows:

; Maximum amount of memory a script may consume (128MB)
; http://php.net/memory-limit
;memory_limit = -1
memory_limit = 128M

Also sprach Uncle Vanya ;-)

A new website for Silvio "Gnaro" Mondinelli

1 commento » Announcements , News 1 Comment »

For several days is online the new website of Silvio Mondinelli, the legendary Italian mountaineer known to most by his nickname around Brescia Gnaro.

For the few who do not know or layman, remember that Silvio Mondinelli has participated in twenty shipments on "eight thousand", in 16 of them managed to reach the summit. He climbed all the main peaks of the 14 eight thousand of the earth, entering into the restricted album of those who have completed the "race to eight thousand" was the sixth man to succeed in the world without ever making use of supplemental oxygen. In 2001, only 5 months has climbed eight thousand 4: Everest , Gasherbrum I , Gasherbrum II and Dhaulagiri .

The GNARO is also the protagonist of laudable initiatives in the field of international cooperation.

For more information: http://www.gnaromondinelli.it/cms/

Mom ... I go out!

Nessun commento » Comics , Miscellaneous No Comments »
MTV On Demand
Watch all the videos from the best show on MTV in exclusive only on MTV On Demand
ARE YOU WATCHING: Seeing Mom - I'm going for the ca .. my | The Idiots