Skip to content

Instantly share code, notes, and snippets.

View ppsilv's full-sized avatar

Paulo da Silva ppsilv

  • To push use the https://github.com/ppsilv/cppDES getToken with key <o nome do filho do cara>
View GitHub Profile
@ppsilv
ppsilv / rc2014.md
Created July 29, 2022 20:40 — forked from jblang/rc2014.md
RC2014 Links
@ppsilv
ppsilv / bind_socket.py
Created April 24, 2023 14:27 — forked from tuxfight3r/bind_socket.py
python tcp socket client / server examples
#!/usr/bin/python
import socket #for sockets
import sys #for exit
try:
#create an AF_INET, STREAM socket (TCP)
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
except socket.error, msg:
print 'Failed to create socket. Error code: ' + str(msg[0]) + ' , Error message : ' + msg[1]
Existem várias tipos de items que podem ser criados no zabbix, porém como estou iniciando os estudos sobre o zabbix eu entendi somente alguns.
Simple check, http agent e script.
Pelo que pude entender sobre o zabbix com esses items voce pode criar seus templates para monitorar o que voce quizer.
* Simple check - esse tipo permite que voce crie templates com items já existentes no zabbix para que voce tenha um template mais objetivo
para suas necessidades.
Voce já tem items pré-criados no zabbix como esses.
Exemplos:
* Quantidade de cores na cpu.
* Quantidade de memória.
Create this dir
/etc/systemd/system/run-docker-.mount.d
Create this file
/etc/systemd/system/run-docker-.mount.d/10-silence.conf
Add this content
[Mount]
LogLevelMax=notice
Relead the system
sudo systemctl daemon-reload
To compile linux drivers
1 - You must have a correct environment with the linux headers for your kernel or for the kernel you are compiling the driver maybe you are crosscompiling the driver
thing that I don't know it is possible.
* For orangepi 5 plus the kernel and ubuntu 22.04 jammy header are in /opt
when I am writing this the package is: /opt/linux-headers-legacy-rockchip-rk3588_1.0.6_arm64.deb for the kernel 5.10.110-rockchip-rk3588, use uname -r to get your
kernel version.
* Some distributions you can use apt-get install linux-headers$('shell uname -r')
* Unforunately you will must discover how to get your linux kernel headers.
@ppsilv
ppsilv / openMediaVaultInstall.txt
Created October 17, 2023 00:52
Open media vault Raspberry PI installation
Installation Instructions
Recently the folks at 52pi.com reached out and asked if they could send me a Mini Tower NAS Kit for me to review here on the channel.
I told them that the case looked great, but I couldn't just post a review of a raspberry pi case. However, if they wanted to send over a pi 4 to put in it, I could make some content that included the case.
They agreed and sent over the Mini Tower NAS Kit and a pi 4 4gb.
A few days ago I made a short where I put it together to prep for the video you're watching now. As I mentioned in the short, the case only took about 20 minutes to install even with recording and whatnot.
@ppsilv
ppsilv / motd
Created October 18, 2023 02:14
colored motd file .
^[[32m
DDDDD DD D DDDDD DDDDD
D D DD D D D
D D D D D D D eee r rrr v v eee r rrr
D D D D D DDDDD DDDDD e e r v v e e r
D D D D D D D eeee r v v eeee r
D D D DD D D e r v v e r
DDDDD DD DD DDDDD DDDDD eeee r v eeee r
^[[31m
@ppsilv
ppsilv / motd.d
Created October 18, 2023 02:25
Another way to have a colored motd
Create the the following file
sudo vim /etc/update-motd.d/10-uname
Content of this file.
#!/bin/sh
export TERM=xterm-256color
read one five fifteen rest < /proc/loadavg
echo "$(tput setaf 2)
Kernel: `uname -v | awk -v OFS=' ' '{print $4, $5}'`
@ppsilv
ppsilv / 30-sysinfo
Created October 18, 2023 05:10
This file must be put into /etc/update-motd/ directory and chmoded to exectable.
#!/bin/bash
#
# 30-sysinfo - generate the system information
# Copyright (c) 2015 Igor Pecovnik
# define which hard drive you want to monitor
#storage=/dev/sda1
storage=/dev/mmcblk0p2
@ppsilv
ppsilv / mainline_guide.md
Last active November 14, 2023 02:41 — forked from lategoodbye/mainline_guide.md
Raspberry Pi: How to cross-compile and use Mainline Kernel

Raspberry Pi: How to cross-compile and use Mainline Kernel

Notes on how to set up a new Ubuntu 18.04 LTS x64 environment, how to build the Mainline Kernel and place it on a Raspberry Pi OS SD card.

Procedure

  1. Install tools needed:
$ apt install git make gcc g++ device-tree-compiler bc bison flex libssl-dev libncurses-dev python3-ply python3-git libgmp3-dev libmpc-dev