How to configure static routes in Fedora

Você pode ver este post em português também. Routes. The unique way I like to see them: Recently I had to do a fix inside the routing table of a server. I’ve found out a better and more elegant way than this usual: touch /etc/rc.d/rc.local echo "touch /var/lock/subsys/local" > /etc/rc.d/rc.local echo "route add default gw 10.10.0.1 eth0" > /etc/rc.d/rc.local echo "route add -net 10.1.0.0 netmask 255.255.0.0 gw 10.2.0.1 eth0" > /etc/rc.d/rc.local Inside Fedora GNU/Linux, static routes can be added in specific files for each one of its interfaces. These files are located at /etc/sysconfig/network-scripts/. The filename must match the route-ifname format.

READ MORE

Fedora installed IN the USB stick

Você pode ver este post em português também. “Long time no see, blog” ;-) ](http://blog.argl.eng.br/pt/wp-content/uploads/2012/01/daniel_faraday_long_time_no_see.png) For a while I tried to use the XFCE Spin from Fedora as an alternative to continue on GNU/Linux and keep the corporate laptop without changes in your default settings. Upset with the performance of the Live ISO, I decided to do the OS installation directly on the USB stick. The difference, at performance at all, is impressive. If like me, you do want to have a distro ready to allow you keep working even on a PC other than your own, forget the LIVE versions and install the OS directly on the USB stick.

READ MORE

10 stupid tips for MySQL

Você pode ler este post em português também. Hello! The April’s post brings 10 stupid tips for day-by-day work with MySQL. Let’s see them: Use a .my.cnf file in your homedir with user/password data: \[client\] user=root password=my\_p@ss-w0rd End your commands with \G instead of ";": This will bring a “form” view instead the normal tabular view. This is necessary a lot of times; Materialized views: When the regular views (created with CREATE VIEW) doesn’t offer the expected performance, use triggers to feed tables that could work like the regular views. Being carefull, it helps a lot! Take care of the parameter ENGINE of your databases and tables: Choose the best considering the R/W relation of the tables;

READ MORE

Vacations!!

Você pode ler este post em português também. To all who follow this blog, February was a month that I devoted myself entirely to family and vacations, and that’s why I didn’t write posts at February. And you should know what happens to the amount of work when we went 25 days away in vacations :-) ASAP, another article about PHP will be writen. And I want to re-organize my site and blog at all, so… See you ;-)

READ MORE

Beware with flags!!

Você pode ler este post em português também. Hello! The first article of this year talks about data modeling. A situation that makes me angry for years is when you have attributes that work as flags inside tables. Think twice (or maybe three times) before create them because usually, they are unnecessary. And why? We create them to mark a state of a record, which can be done, many times, querying another attributes, generating duplicity situations (so much problematic, per si). Let’s see examples: mysql> SELECT - FROM tb\_orders LIMIT 5; +------------ ... +--------------+------------ ... +----------------+ | order\_id ... | sent\_method | sent\_date .

READ MORE