Notepad:Notepad: Difference between revisions

From Amar
Jump to navigationJump to search
→‎Hackintosh: Monterey Patch
Line 237: Line 237:
  You need to find
  You need to find
  41 c7 45 00 00 00 00 00 e9
  41 c7 45 00 00 00 00 00 e9
 
  and replace it with
  and replace it with
  41 c7 45 00 01 00 00 00 e9
  41 c7 45 00 01 00 00 00 e9

Revision as of 18:23, 9 January 2022

Unfiled

#threadTree treechildren::-moz-tree-row(odd) {
 -moz-appearance: none !important;
 background-color: #your_color_here !important; }

#threadTree treechildren::-moz-tree-row(odd, selected) {
 background-color: Highlight !important;
}

Windows

C:\WINDOWS\system32>PowerCfg /SETACVALUEINDEX SCHEME_CURRENT SUB_PROCESSOR IDLEDISABLE 000
C:\WINDOWS\system32>PowerCfg /SETACTIVE SCHEME_CURRENT
 DISM /Online /Cleanup-Image /RestoreHealth /source:WIM:F:\Sources\Install.wim:1 /LimitAccess 
 DISM /Online /Cleanup-Image /RestoreHealth /source:F:\sources /LimitAccess

URLs

Linux Tricks

Linux stuff I often have to lookup. Just my personal list of things.

shutdown -rF now
xauth add `hostname`/unix:0 . `openssl rand -hex 32`
  • yum versionlock - allows to lock an rpm
  • install faster random for dns etc.
yum install haveged;
systemctl enable haveged;
systemctl start haveged
sudo visudo -f /mnt/etc/sudoers
netstat -tulpn
xargs yum -y install < file
  • Create Default Home Directory
mkhomedir_helper username
use tmpfiles.d and have your package create at startup or boot a file or directory /usr/lib/tmpfiles.d/mydaemon.conf :
man tmpfiles.d

#Type Path            Mode UID      GID    Age Argument
d     /run/mydaemon   0755 myuser myuser   -   -
rpm -Uvh --nodeps $(repoquery --location <module>)
  sudo journalctl --vacuum-time=3weeks

MySQL

  • UTF8
  • Get a list of processes to kill
 SELECT GROUP_CONCAT(CONCAT('KILL ',id,';') SEPARATOR ' ') 
 'Paste the following query to kill all processes' 
 FROM information_schema.processlist 
 WHERE user<>'system user'
 
  • install latest MariaDB
curl -sS https://downloads.mariadb.com/MariaDB/mariadb_repo_setup | sudo bash
  • Move/Rename a DB to another
mysql -u username -ppassword old_db -sNe 'show tables' | while read table; \ 
   do mysql -u username -ppassword -sNe "rename table old_db.$table to new_db.$table"; done
  • database dump without charset
  mysqldump -u <user> -p --skip-add-locks --skip-set-charset <DB> <tables ...>
  • Disable foreign key checks in a session
SET FOREIGN_KEY_CHECKS=0;

SSL Certificates

Version Control

  git update-index --chmod=+x filename.sh

Oracle

SC Backup

Matricom gBox Q

KVM

QNAP

Zend Framework

Video ffmpeg

Convert wmv to mp4

ffmpeg -i <input> -c:v libx264 -c:a aac -strict -2 -q:a 100 -crf 23 <output>

Zimbra

AWS

letsencrypt certonly --webroot -w /var/www/mydomain -d mydomain.com -d www.mydomain.com -w /var/www/cool-site -d cool-site.com -d www.cool-site.com
    • deploy new cert to all
    • upload into AWS *Load Balance* *Listeners* *SSL Certificate* (We get a weird error but it works)
    • Load balance instances back to all

Hackintosh

pmset -g assertions

These are the steps

  1. replacing the drivers > UEFI > AptioMemoryFix.efi with OpenRuntime.efi
  2. Also, add OcQuirk.efi (More Info: https://github.com/ReddestDream/OcQuirks)
  3. select: config.plist/Quirks > DisableIoMapper
Kext to patch
com.apple.driver.AppleEthernetAquantiaAqtion

Find
41C70424 00000000 E9

Replace
41C70424 01000000 E9

comment
Marvell AQC107 10GBE Patch

We've got to modify the patch.

You need to find
41 c7 45 00 00 00 00 00 e9

and replace it with
41 c7 45 00 01 00 00 00 e9

Firefox

about:config

layout.css.devPixelsPerPx

to set the textsize on high res displays



<insert>googlesearchwiki</insert> <insert>paypal</insert> <insert>analytics</insert>