Posts about linux

Mysql access denied for user root

03 November 2017

Clean installation of mysql-server on Ubuntu (also happened to me on Debian), i can't connect with root and no password (even though on installation i set a blank password). This is not MariaDB, it's the proper 5.7 version installed via package repository after using the Mysql APT tool to set it up.

Here's the shit i had to do to make this work:

sudo emacs /lib/systemd/system/mysql.service

In this file, add --skip-grant-tables to the Exec command. After that run:

sudo systemctl daemon-reload

Lock and unlock Ubuntu using your iPhone

18 January 2016
If, like me, you suffer from lazius extremis (lazy bastard, for the layman), you probably hate having to lock your computer when you leave and entering a password when you come back.

Fear not, young padawan, UDEV and xdotool to the rescue!

Here's how it works: UDEV (a linux mechanism that detects device events (including USB)) can be configured with rules that fire whenever something changes (i.e. a device is connected or disconnect from the system). When that happens, you want to run a scrip...

FISH Shell - How to set tmux window/pane title based on current command and directory

24 January 2015

Here's a neat trick: Setting the current tmux window/pane title to the current running command. In case there is no command running, show the current working directory. But trim it a little, so we don't end up with huge window titles :)

In your file add the following functions:

# Set the tmux window title, depending on whether we are running something, or just prompting function fish_title if [ "fish" != $_ ] tmux rename-window "$_ $argv" else ...

Displaying posts 1 - 3 of 5 in total