Archive

Posts Tagged ‘crash’

Filezilla 3.5 crashes when drag&drop a file (Ubuntu 11.10 64 bits)

January 18, 2012 Leave a comment

When I try to drag & drop a file from left pane to right pane, filezilla crashes due to a segmentation faul. This is the dmesg output:


[73197.174428] filezilla[18057]: segfault at 41 ip 00004f26ec47d100 sp 00008fffff165f50 error 4 in libwx_gtk2u_core-2.8.so.0.7.0[8f26ec2a5000+386000]
[73232.550023] filezilla[18241]: segfault at 2227140 ip 0000000004227140 sp 00008fff0623a508 error 15
[73272.918743] filezilla[18416]: segfault at 18db940 ip 00000000048db940 sp 00008fffc42c7ac8 error 15

I searched around for this bug (already reported to filezilla) and the fix is to install the newer version of wxWidgets (2.8.12, the latest stable release). This is how to solve in Ubuntu 11.04:

http://wiki.wxpython.org/InstallingOnUbuntuOrDebian

But this fix doesn’t work for ubuntu 11.10 64 bits (with Gnome 3). I’m still getting the segmentation fault.

So, I decided to build the latest version of wxWidgets (2.9.3.1):


$ sudo python2.7 build-wxpython.py --build_dir=../bld --install

[...]

configure: error: OpenGL libraries not available
Error running configure
ERROR: failed building wxWidgets
Traceback (most recent call last):
 File "build-wxpython.py", line 352, in
 wxbuild.main(wxscript, build_options)
 File "/home/miquelete/wxWidgets/wxPython-src-2.9.3.1/build/tools/build-wxwidgets.py", line 328, in main
 "Error running configure")
 File "/home/miquelete/wxWidgets/wxPython-src-2.9.3.1/build/tools/build-wxwidgets.py", line 62, in exitIfError
 raise builder.BuildError, msg
BuildError

Install the open source openGL Utility Toolkit:


sudo apt-get install freeglut3 freeglut3-dev

And now I get another error:


checking for GST... configure: WARNING: GStreamer 0.10 not available, falling back to 0.8
checking for GST... configure: WARNING: GStreamer 0.8/0.10 not available.
configure: error: GStreamer not available
Error running configure
ERROR: failed building wxWidgets
Traceback (most recent call last):
 File "build-wxpython.py", line 352, in
 wxbuild.main(wxscript, build_options)
 File "/home/mike/wxWidgets/wxPython-src-2.9.3.1/build/tools/build-wxwidgets.py", line 328, in main
 "Error running configure")
 File "/home/mike/wxWidgets/wxPython-src-2.9.3.1/build/tools/build-wxwidgets.py", line 62, in exitIfError
 raise builder.BuildError, msg
BuildError

I need GStreamer package. I’ve tried a bunch of packages to get it work, sure that some of them are not requiered, but this worked for me:

$ sudo apt-get install ubuntu-restricted-extras
$ sudo apt-get install gstreamer0.10-ffmpeg gstreamer0.10-fluendo-mp3 gstreamer0.10-gnonlin gstreamer0.10-sdl gstreamer0.10-schroedinger gstreamer0.10-plugins-ugly totem-plugins-extra
$ sudo apt-get install libgstreamer-plugins-base0.10-0 libgstreamer0.10-0 libxml2
$ sudo getlibs -p gstreamer0.10-pitfdll
$ sudo apt-get install libgstreamer0.10-0 libgstreamer0.10-dev gstreamer0.10-tools gstreamer0.10-plugins-base libgstreamer-plugins-base0.10-dev gstreamer0.10-plugins-good gstreamer0.10-plugins-ugly gstreamer0.10-plugins-bad gstreamer0.10-ffmpeg

Now I can build, but during the make install I get this one:

src/helpers.cpp:15:20: fatal error: Python.h: No such file or directory

compilation terminated.
error: command 'gcc' failed with exit status 1
ERROR: failed building wxPython.

This is because I don’t have Python.h in /usr/include/python2.7/. To get it, install this package:

$ sudo apt-get install python-dev

Once added this package, the installation
Change to ../bld folder and check the version of wxWidgets:


$ wx-config --version
2.9.3

And now I can get it work!

Restore MySQL database without a mysqldump backup

September 6, 2011 2 comments

Restore the database

I have had a hard disk error and I need to restore my old redmine database to the newer installation of redmine in Ubuntu 11.04 (https://myotragusbalearicus.wordpress.com/2011/09/05/install-redmine-with-mysql-in-ubuntu-11-04/).

I have the old data directory accessible, but no recent mysqldump of my database, so I just want to copy the old data directory to the newly created redmine database.

First, I take a backup of the current version:

$ mysqldump -u root -p'root_password' redmine | gzip > redmine_mysql.gz

Shutdown the database:


$ sudo service mysql stop

Delete all of MySQL database files (with root user or mysql user):


$ sudo su -

$ cd /var/lib/mysql/

$ rm *

Install a new empty database schema:

$ mysql_install_db
Installing MySQL system tables...
OK
Filling help tables...
OK

To start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your system

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:

/usr/bin/mysqladmin -u root password 'new-password'
/usr/bin/mysqladmin -u root -h <machinename> password 'new-password'

Alternatively you can run:
/usr/bin/mysql_secure_installation

which will also give you the option of removing the test
databases and anonymous user created by default.  This is
strongly recommended for production servers.

See the manual for more instructions.

You can start the MySQL daemon with:
cd /usr ; /usr/bin/mysqld_safe &

You can test the MySQL daemon with mysql-test-run.pl
cd /usr/mysql-test ; perl mysql-test-run.pl

Please report any problems with the /usr/scripts/mysqlbug script!

Start the database and then assign a password to the root user:

$ sudo service mysql start
$ mysqladmin -u root password 'new-password'

Shutdown again the database, and copy all of the files of the old filesystem to the newly created database, overwriting all the files:

$ sudo service mysql stop
$ sudo su -
$ cp -R /old_file_system/var/lib/mysql/* /var/lib/mysql
$ chmod -R 660 /var/lib/mysql/

And finaly, restart the database:

$ sudo service mysql start

Permissions error

If you get this error selecting tables:

mysql> select * from attachments;
ERROR 1017 (HY000): Can't find file: './redmine_default/attachments.frm' (errno: 13)
mysql>

Ensure that you have the propper permissions in the data directory and that belongs to mysql user.
In my case, the data files has the correct permissions:

$ ls redmine_default/attachments.frm
-rw-rw---- 1 mysql mysql  9022 2011-09-06 00:02 attachments.frm

But the directory not:

$ ls redmine_default
drw-rw----  2 mysql mysql     4096 2011-09-06 00:02 redmine_default/

The directory needs 770 permissions:

$ sudo chmod 700 redmine_default

Rollback changes

If something goes wrong, and you need to restore the initial backup, you have to do this:

$ gzip -c -d redmine_mysql.gz | mysql -u root -p redmine

Restore redmine attachments

The attachments are installed under /var/lib/redmine/default/files. To back them up run the following:

</pre>
<code>$ sudo tar zcPf redmine_attachments.tar.gz /old_file_system/var/lib/redmine/default/files</code>

And to extract to the new location:

<span class="Apple-style-span" style="font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 13px; line-height: 19px; white-space: normal;">$ sudo tar xvPf redmine_attachments.tar.gz</span></pre>

Youtube hangs firefox on ubuntu 10.10 64 bits

January 14, 2011 Leave a comment

Well, it’s really flash plugin that hangs my FF on ubuntu 10.10 64 bits

I’ve installed flash-aid as a firefox plugin from http://www.webgapps.org/addons/flash-aid and now it works fine.

Categories: bug, firefox, ubuntu Tags: , , ,