Skip to content

Instantly share code, notes, and snippets.

@sysadminbp
sysadminbp / gist:b454a3c20837d035f37b02057ba48459
Last active March 13, 2022 12:19
fix scroll tearing in linux
# fix scroll tearing
apt-get install -y driconf mesa-utils ; mkdir -p /etc/X11/xorg.conf.d/ ;
touch /etc/X11/xorg.conf.d/20-intel.conf /etc/X11/20-intel.conf; chmod -R 777 /etc/X11/xorg.conf.d/ /etc/X11/xorg.conf.d/20-intel.conf /etc/X11/20-intel.conf ;
cat > /etc/X11/xorg.conf.d/20-intel.conf <<EOL
#################
Section "Device"
Identifier "Intel Graphics"
Driver "intel"
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Classes\CLSID\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}\InprocServer32]
@=""
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PolicyManager\default\Start\HideShutDown]
"value"=dword:00000001
First of all you need two identical mysql versions of mysql, example: 5.7.2 and 5.7.32. 5.7.X with not-5.7.x WILL WORK ONE SIDE ONLY!
===========================
====Master====
[mysqld]
server_id = 1
binlog-do-db = databasename
replicate-do-db = databasename
-A DOCKER-USER -s 1.1.1.1/32 -i eth0 -p tcp -m tcp -m conntrack --ctorigdstport 8080 -j ACCEPT
-A DOCKER-USER -s 2.2.2.2/32 -i eth0 -p tcp -m tcp -m conntrack --ctorigdstport 8080 -j ACCEPT
-A DOCKER-USER -i eth0 -p tcp -m tcp -m conntrack --ctorigdstport 8080 -j DROP
First of all you need two identical mysql versions of mysql, example: 5.7.2 and 5.7.32. 5.7.X with not-5.7.x WILL WORK ONE SIDE ONLY!
================= my.cnf configuration ==================
-----master (1.1.1.1) (where database is located now)
[mysqld]
# Unique identifier
server_id = 1
# [master] incrementation of auto-increment ID in the tables - 1 3 5 ....
# Copyright 2017 The Perkeep Authors.
FROM openjdk:8-jdk
MAINTAINER Perkeep Authors <[email protected]>
CMD ["./gradlew"]
# To enable running android tools such as aapt
RUN apt-get update && apt-get -y upgrade
This will help you activate Microsoft Windows 10/11
===================================================
Run CMD as Administrator these 3 commands:
[1] slmgr /ipk [windows_key_from_below]
Home: TX9XD-98N7V-6WMQ6-BX7FG-H8Q99
Home N: 3KHY7-WNT83-DGQKR-F7HPR-844BM
Home Single Language: 7HNRX-D7KGG-3K4RQ-4WPJ4-YTDFH
SHOW GLOBAL VARIABLES LIKE 'expire_logs_days' ; - shows how much days are set now
======
SET GLOBAL expire_logs_days = 3; - sets variable for 3 days
/etc/my.cnf:
[mysqld]
expire_logs_days=3
@sysadminbp
sysadminbp / disablewindows10photoviewer.reg
Last active June 13, 2020 09:59
Enable "Windows Photo Viewer" in Windows 10
Windows Registry Editor Version 5.00
[-HKEY_CLASSES_ROOT\Applications\photoviewer.dll]