Get first and last line of file


bash way
(head -1; tail -1) < /etc/passwd

sed way
sed -n '1p; $p' /etc/passwd

awk way
awk 'NR==1; END { print }' /etc/passwd

Obter certificado do servidor para LDAPS no Linux

 Pegar certificado LDAPS: 1. Conecte-se ao servidor com openssl s_client ex: openssl s_client -connect ldap.example.com:636 -showcerts Isso ...

Mais vistos