It is my space, but better than myspace


Bookmark – GIT Remove files with wrong line endings

1) Remove every file from Git's index.

git rm --cached -r .

2) Rewrite the Git index to pick up all the new line endings.

git reset --hard

Filed under: bookmark No Comments

Rescan For Disks Without Rebooting

for host in /sys/class/scsi_host/*; do echo "- - -" | sudo tee $host/scan; ls /dev/sd* ; done


Filed under: bookmark No Comments

Online PowerShell UI and IDE

Filed under: bookmark No Comments

Cannot connect with MySQL Workbench but can connect from shell with mysql command line client

Taken from for my own reference:


The issue is likely due to socket authentication being enabled for the root user by default when no password is set, during the upgrade to 16.04. This important caveat is documented in the 16.04 release notes:

Password behaviour when the MySQL root password is empty has changed. Packaging now enables socket authentication when the MySQL root password is empty. This means that a non-root user can't log in as the MySQL root user with an empty password.

For whatever reason, the MySQL Workbench that came with 16.04 doesn't work out of the box with MySQL server, at least for me. I tried using "Local Socket/Pipe" to connect in a number of different ways but to no avail.

The solution is to revert back to native password authentication. You can do this by logging in to MySQL using socket authentication by doing:

sudo mysql -u root

Once logged in:

ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';

which will revert back to the native (old default) password authentication. If you've attempted some other method to fix the issue, you'll want to make sure the "plugin" field in mysql.user is set to "auth_token", which may require using mysqld_safe to log in to MySQL in the event you've been tinketing with things, like I did.

Credit to Miguel Nieto's blog post for this solution.

Filed under: bookmark No Comments

Bookmark: Running EXE Over UNC

Apparently, on server2008, despite a domain-wide GPO was applied dictating the trusted sites zone, it seemed to be NOT applied to server2008 !

More specifically, you can see in Internet Options, tab Security, a yellow info line stating that "Some settings are managed by your system administrator", but when checking the list with Trusted sites, this turns out to be empty !

The exact GPO setting I'm referring to:
Computer Configuration > Administrative Templates > Windows Components > Internet Explorer > Internet Control Panel > Security Page :
Site to Zone Assignment List     ENABLED
With (example):
http://*     2
http://*                2

Despite this setting, when checking in IE on any Server2008, the list of sites in Trusted Zone is EMPTY !!

This is caused by the fact that by default Internet Explorer Enhanced Security Configuration  (IE ESC) is ENABLED for both users and administrators !

You can disable it for administrators:
Start > Administrative Tools > Server Manager
under Security Information, click Configure IE ESC

Under Administrators : click Off.
Now, after closing and reopening IE, you will find the list with Trusted Sites in place !


The correct step is this way: User Configuration > Administrative Templates > Windows Components > Internet Explorer > Internet Control Panel > Security Page

“Site to Zone Assignment List” , click “Enable” and edit the list.

Add the site and the number two for Trusted Site. (1 = Intranet, 2 = trusted sites, 3 = Internet Zone and 4 = Restricted Site Zone.

To have a list like that (2 is for trusted site)

* 2

* 2

* 2

The PRO of that method:

- It standardizes all domain-joined computers as they will use the same list for everyone.

- It blocks users from entering new trusted sites. Though this can be a con for small offices or for Power Users wanting more autonomy.

The CON of this method:

- It block user for entering new trusted sites. This can be considered a PRO in big offices, as the list is standardized by the IT's team.


Go to Group Policy and then expand:


Local Computer Policy / User Configuration / Administrative Templates / Windows Components / Attachment Manager


2.     On the right pane, double click Inclusion list for low file types.

3.     Click Enable.

4.     Include the file types such as .exe;.bat;.reg;.vbs in the Options box.

5.     Click OK.


Hope this helps.





Filed under: bookmark No Comments