2015/08/13

Installing Win + Linux Slackware on a Mac Book Pro 5 with lilo

here's a list of the things I did to successfully install Windows Vista and Linux Slackware 14 on a MBP 5 (after a lot of tries).


1) booted up using Slack CD ROM, deleted the GPT using the zap command
2) then booted up using the Win CD and installed using some space of the hard disk. And then I made sure the computer would boot it.

3) then booted up under Linux, repartitioned using fdisk, created swap and root filesystem, but I left marked as bootable only the Linux partition

4) setup as normal
5) when asked by lilo, I choose Automatic setup and install into MBR

Apparently Mac doesn't need the GPT or it's rebuild automatically on reboots. But MBR needs only one partition active.

2015/03/12

MySQLDump

how to properly dump a complete catalog (this post is a work in progress)



    mysqldump --login-path=XX database_here --add-drop-database --add-drop-table --add-drop-trigger --add-locks --comments --disable-keys --dump-date --lock-all-tables --log-error=/tmp/mysqldump.log --routines >/data/$RUTA/$SQLLOG

saving SPs only:

    mysqldump --routines --no-create-info --no-data --no-create-db --skip-opt database_here > outputfile.sql

    

2014/09/13

MySQL Multi configuration

Example configuration of a mysqld instance in Slackware 14

root@trax:/etc/rc.d# cat /etc/my.cnf
[client]port=3307
socket=/tmp/mysql.sock2

[mysqld_multi]
mysqld     = /usr/bin/mysqld_safe
mysqladmin = /usr/bin/mysqladmin
user       = mysql
password   = mysql

[mysqld2]
socket     = /tmp/mysql.sock2
port       = 3307
pid-file   = /usr/local/mysql/var2/hostname.pid2
datadir    = /usr/local/mysql/var2
language   = /usr/local/share/mysql/english
user       = mysql

mkdir /usr/local/mysql/var2
cd /usr/local/mysql/
chown mysql.mysql var2

cd /usr
mysql_install_db --user=mysql --datadir=local/mysql/var2 --basedir=/usr

if needed copy mysqld.server.multi to /etc/rc.d

/etc/rc.d/mysql_multi start N

mysqladmin -uroot password --socket=/tmp/mysql.sock --port=PORT

mysql -uroot -p --socket=/tmp/mysql.sock --port=PORT

and allow root access if needed

2014/05/17

Must Have Firefox Addons

No Script: because it doesn't really matter if there's a hole in the newest  JavaScript  version for firebox. Link

Ad Block Plus: get rid of most nasty ads. Link

Cookie Monster: site cookies can store information on your browser about your preferences, but can also used to track you on the Internet.  Link

DTA (Download Them All): I'm not a mass downloader but this Addon is a must with Unplug. Link

Firebug: a must have for web hacking. Link

Lazarus: after typing 10 times the same form, you end up installing this.  Link

Skip Feedsportal: some RSS Feeds create a special formated url to keep a track of the sites you visit. If you don't want that, this Addon is for you. Link

Stylish: Check on my other posts to see what can you do with it. Link

Tabs on Bottom: as firefox user since version 1 I like the old style more than the new one. Link

Unplug: Extract media from web pages like Youtube. Link

User Agent Switcher: In some cases, if a web pages is acting weird, you can force them to believe you are using a different browser.  Link


2014/04/30

A bit more anonymous way for Youtube browsing


If you use Google productos like blogger or gmail, you will notice that entering in Youtube automatically use your google credentials on the site. Which means all videos you search and browse are registered in your Google Account.

If you want to avoid that, you need Firefox and Cookie Monster. Once installed you will have a new Icon with the letters CM, go to youtube, click on the icon and select Cookie Access (site level) and select Reject Cookies. You will notice that even if you use gmail or blogger or even google it wont log you out from those sites.

2014/04/23

How to get rid of "Try the new Twitter profile" box on Twitter

EDIT 20140603: this post is outdated since Twitter forced the new style on every account

ORIGINAL POST:

same thing as this post, You need Firefox, Stylish and create a new style for the domain.

@namespace url(http://www.w3.org/1999/xhtml);

@-moz-document domain("twitter.com") {
.ProfilePreviewBanner

{background:none !important;display:none !important}

}


Edit: Added screenshoots as example. notice the icon in the left lower corner:




@namespace url(http://www.w3.org/1999/xhtml);

@-moz-document domain("twitter.com") {
.ProfilePreviewBanner

{background:none !important;display:none !important}

}
@namespace url(http://www.w3.org/1999/xhtml);

@-moz-document domain("twitter.com") {
.ProfilePreviewBanner

{background:none !important;display:none !important}

}

2014/04/20

Slackware: post installation

this page is going to be a reminder to myself about thing that should be done after installing Slackware. I'm not posting quite obvious things like running xorgconf.

Adding cdrom, printer and audio rights to the normal user I should normally use.

usermod -G lp,audio,cdrom username

Adding a line in /etc/rc.d/rc.local_shutdown to remove all the files in /etc/udev/rules.d, helps a lot when the underlying hardware changes or when having more than one Ethernet card with the same chipset.

If you plan to use squid, don't forget to add a rc.local_shutdown line to shut it down or it might break the cache on the process.

If the cache becomes a problem, create an script to stop it, remove the cache and restart it.

if situation allows it, going for ethernet bonding is a must.

http://www.sgvulcan.com/network-interface-bonding-in-slackware-version-13-1/

create a personal bin directory for scripts in your home dir

mkdir ~/bin
echo export PATH=$PATH:~/bin >~/.bash_profile