I am using on one project InnoDB type of tables. There is very important have actual data. So I am actively using foreign keys for tables linking. And once I came across problem when tried to delete from table (`group`) which linked by foreign key with another table (`subgroup`) which linked by foreign key with [...]
Posted on November 14th, 2011 by admin
Filed under: Development | Comments Off
Perhaps you know redmine ported in FreeBSD and first of all I tried to install it: #cd /usr/ports/www/redmine ===> redmine-1.2.1_1 is marked as broken: Does not work with RubyGems 1.8. *** Error code 1 Stop in /usr/ports/www/redmine. Sure. You wouldn’t read this post if process had been done successfully Maintainer of this port marked this [...]
Posted on October 22nd, 2011 by admin
Filed under: Software | 4 Comments »
Converting file from KOI8-R to utf-8: #iconv -f KOI8-R -t utf-8 originalfile > newfile You can change KOIR-8 and utf-8 to yours. Batch converting files from folder: #mkdir new; for a in $(find . -name “*.php”); do iconv -f KOI8-R -t utf-8 <”$a” >new/”$a” ; done It will make “new” directory with converted files.
Posted on September 10th, 2011 by admin
Filed under: Development | Comments Off
Just a few notes about mysqldump. Create dump of mysql base: # mysqldump -uDBUSER -pPASSWORD DBNAME > filename.sql or # mysqldump –user=username –password=password DBNAME > filename.sql if you need to make dump of a few databases you can use parametr -B (or –databases): mysqldump -uDBUSER -pPASSWORD -B DBNAME1 DBNAME2 > filename.sql Make dump of the [...]
Posted on July 5th, 2011 by admin
Filed under: Development, Software, Tips | Comments Off
If you want to activate logging of mysql queries, add in your my.cnf (by default it is /var/db/mysql/my.cnf) in [mysqld] section: log=/var/log/mysql.log create log file: #touch /var/log/mysql.log #chmod 666 /var/log/mysql.log and restart mysql-server: #/usr/local/etc/rc.d/mysql-server restart (it can be different on you server) That is all. PS: I don’t recommend you use it on hight loaded [...]
Posted on March 10th, 2011 by admin
Filed under: Tips | Comments Off
Everybody who worked with svn knows fine svn client for windows TortoiseSVN. But what are we have similar for the linux (especially for FreeBSD). “True”-developers will say “I use console svn client and don’t want anything else” and will be right. Although many users wants user-friendly interface. So, today I want introduce you svn client [...]
Posted on December 26th, 2010 by admin
Filed under: Software | Comments Off
It’s also possible for create copyes svn repositoryes or create svn backups. $svnadmin dump /svnroot/repository > name.dmp After that you can compress dump file and get it to your server where you want create copy of you repository. Create a new repository: $svnadmin create /svnroot/repository import dump in new repository $svnadmin load /svnroot/repository < name.dmp [...]
Posted on March 17th, 2010 by admin
Filed under: Software | Comments Off
cvs -d :pserver:john_ts@cvs.dev.java.net:/cvs checkout glassfish/bootstrap … maven -Djava.net.preferIPv4Stack=true checkout … maven -Djava.net.preferIPv4Stack=true bootstrap-all … maven -Djava.net.preferIPv4Stack=true build … maven -Djava.net.preferIPv4Stack=true configure-runtime … It’s all! PS: I should give you one advice – don’t try build glassfish with openjdk6 or diablo-jdk-1.6! I have built it only with diablo-jdk-1.5. If you know how to build glassfish with [...]
Posted on November 16th, 2009 by admin
Filed under: Software | 1 Comment »