Skip to content

Instantly share code, notes, and snippets.

### version information
```
pre-commit version: 3.3.3
git --version: git version 2.42.0
sys.version:
3.9.2 (default, Feb 28 2021, 17:03:44)
[GCC 10.2.1 20210110]
sys.executable: /root/.local/share/virtualenvs/www.xxx.com-ubuntu-22.04-e7lwHUUs/bin/python
os.name: posix
@basictheprogram
basictheprogram / gist:02e54b3ab5305446bed37f69bd798b9b
Created September 1, 2023 15:11
rsync error: unexplained error (code 255)
File /var/lib/backuppc/pc/hostname.real-time.com/XferLOG.73.z
Contents of file /var/lib/backuppc/pc/hostname.real-time.com/XferLOG.73.z, modified 2023-08-31 23:38:45
XferLOG file /var/lib/backuppc/pc/hostname.real-time.com/XferLOG.73.z created 2023-08-26 23:00:02
Backup prep: type = full, case = 6, inPlace = 1, doDuplicate = 0, newBkupNum = 73, newBkupIdx = 1, lastBkupNum = , lastBkupIdx = (FillCycle = 0, noFillCnt = 0)
Running: /usr/libexec/backuppc-rsync/rsync_bpc --bpc-top-dir /var/lib/backuppc --bpc-host-name hostname.real-time.com --bpc-share-name / --bpc-bkup-num 73 --bpc-bkup-comp 3 --bpc-bkup-prevnum -1 --bpc-bkup-prevcomp -1 --bpc-bkup-inode0 427222 --bpc-log-level 1 --bpc-attrib-new -e /usr/bin/ssh\ -p\ 2222\ -l\ rsyncbackup --rsync-path=sudo\ /usr/bin/rsync --super --recursive --protect-args --numeric-ids --perms --owner --group -D --times --links --hard-links --delete --delete-excluded --partial --log-format=log:\ %o\ %i\ %B\ %8U,%8G\ %9l\ %f%L --stats --checksum --exclude-from=/etc/backuppc/r
$ErrorActionPreference = 'Stop';
$data = & (Join-Path -Path (Split-Path -Path $MyInvocation.MyCommand.Path) -ChildPath data.ps1)
$toolsDir = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)"
$packageArgs = @{
packageName = $env:ChocolateyPackageName
unzipLocation = $toolsDir
fileType = 'exe'
silentArgs = '/S'
---------------------------Script Execution---------------------------
Running 'ChocolateyScriptRunner' for DotNet3.5 v3.5.20160716 with packageScript 'C:\ProgramData\chocolatey\lib\DotNet3.5\Tools\ChocolateyInstall.ps1', packageFolder:'C:\ProgramData\chocolatey\lib\DotNet3.5', installArguments: '', packageParameters: '', preRunHookScripts: '', postRunHookScripts: '',
Running package script 'C:\ProgramData\chocolatey\lib\DotNet3.5\Tools\ChocolateyInstall.ps1'
Running Start-ChocolateyProcessAsAdmin -minimized 'True' -noSleep 'True' -validExitCodes '0' -statements 'cmd.exe /c DISM /Online /NoRestart /Enable-Feature /FeatureName:NetFx3'
Test-ProcessAdminRights: returning True
Elevating permissions and running powershell block:
$noSleep = $True
#$env:ChocolateyEnvironmentDebug='false'
#$env:ChocolateyEnvironmentVerbose='false'
& import-module -name 'C:\ProgramData\chocolatey\helpers\chocolateyInstaller.psm1' -Verbose:$false | Out-Null;
@basictheprogram
basictheprogram / gist:a37e18a71acd1ce88941044f758284a3
Created July 23, 2022 01:33
defaultconfigs/ftbessentials-server.snbt
$ cat ./defaultconfigs/ftbessentials-server.snbt
{
# Teleportation-related settings
teleportation: {
# Allows users to return to their previous location after teleporting (or dying)
back: {
# Cooldown between /back commands (in seconds)
# You can override this with FTB Ranks using ftbessentials.back.cooldown
# Default: 30
# Range: 0 ~ 604800
# systemctl list-unit-files | grep enabled
proc-sys-fs-binfmt_misc.automount static enabled
-.mount generated enabled
cdrom.mount masked enabled
dev-hugepages.mount static enabled
dev-mqueue.mount static enabled
proc-sys-fs-binfmt_misc.mount disabled enabled
sys-fs-fuse-connections.mount static enabled
sys-kernel-config.mount static enabled
sys-kernel-debug.mount static enabled
$ molecule --debug converge
DEBUG Validating schema /Users/tanner/projects/ansible/playbooks.git/roles/procmail/molecule/default/molecule.yml.
INFO default scenario test matrix: dependency, create, prepare, converge
INFO Performing prerun...
INFO Set ANSIBLE_LIBRARY=/Users/tanner/.cache/ansible-compat/129ffd/modules:/Users/tanner/.ansible/plugins/modules:/usr/share/ansible/plugins/modules
INFO Set ANSIBLE_COLLECTIONS_PATH=/Users/tanner/.cache/ansible-compat/129ffd/collections:/Users/tanner/.ansible/collections:/usr/share/ansible/collections
INFO Set ANSIBLE_ROLES_PATH=/Users/tanner/.cache/ansible-compat/129ffd/roles:/Users/tanner/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles
INFO Running default > dependency
WARNING Skipping, missing the requirements file.
WARNING Skipping, missing the requirements file.
ansible-role-apache$ molecule converge
INFO default scenario test matrix: dependency, create, prepare, converge
INFO Performing prerun...
INFO Added ANSIBLE_LIBRARY=/Users/tanner/.cache/ansible-compat/03070b/modules:/Users/tanner/.ansible/plugins/modules:/usr/share/ansible/plugins/modules
INFO Added ANSIBLE_COLLECTIONS_PATHS=/Users/tanner/.cache/ansible-compat/03070b/collections:/Users/tanner/.ansible/collections:/usr/share/ansible/collections
INFO Added ANSIBLE_ROLES_PATH=/Users/tanner/.cache/ansible-compat/03070b/roles:/Users/tanner/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles
INFO Using /Users/tanner/.ansible/roles/geerlingguy.apache symlink to current repository in order to enable Ansible to find the role using its expected full name.
INFO Running default > dependency
WARNING Skipping, missing the requirements file.
WARNING Skipping, missing the requirements file.
# Create the function.
getmode <- function(v) {
uniqv <- unique(v)
uniqv[which.max(tabulate(match(v, uniqv)))]
}
# Create the vector with numbers.
for (z in 1:10) {
   for(f in 1:10) {
     v=sample(c(0,1),1)
$ MOLECULE_DISTRO=ubuntu2004 molecule converge
--> Test matrix
└── default
├── dependency
├── create
├── prepare
└── converge
--> Scenario: 'default'