ldidry / dynamic-motd Goto Github PK
View Code? Open in Web Editor NEWLicense: GNU General Public License v2.0
License: GNU General Public License v2.0
If I am opening a second terminal on to a machine I am usually in a hurry!
I have created this as 00-setup-hush and so now it's only the first terminal that calls sysinfo etc.
#!/bin/bash
echo "user1 user2" > /etc/update-motd.d/hushlogin
who | cut -d ' ' -f 1 | sort | uniq >> /etc/update-motd.d/hushlogin
Hey!
Since I am using this on Raspbian GNU/Linux 10 (buster) (kernel 4.19.71-rt24-v7+) login is taking like 1 min. Any idea?
Hi - After upgrading to Debian 11 from 10, the MOTD no longer displays system information. I have installed python3-utmp as mentioned.
I've also updated 20-system-info for python3. I didn't see any references to python in sysinfo.py
If I run python3 /etc/update-motd.d/sysinfo.py I get the following.
File "/etc/update-motd.d/sysinfo.py", line 72
print " System information as of %s\n" % time.asctime()
^
SyntaxError: invalid syntax
Any ideas?
Many thanks
$hydra -l admin -P pass.txt 192.168.0.1 http-get
Hydra v8.6 (c) 2017 by van Hauser/THC - Please do not use in military or secret service organizations, or for illegal purposes.
Hydra (http://www.thc.org/thc-hydra) starting at 2017-08-14 00:28:13
[WARNING] You must supply the web page as an additional option or via -m, default path set to /
Segmentation fault
can anybody fix this issue
Hello,
the motd only displays this :
_ _
| |__ _ _ __| |_ __ __ _
| '_ \| | | |/ _` | '__/ _` |
| | | | |_| | (_| | | | (_| |
|_| |_|\__, |\__,_|_| \__,_|
|___/
Debian GNU/Linux 8.6 (jessie) (kernel 2.6.32-042stab116.1)
Last login: Mon Oct 24 20:34:29 2016 from
Welcome to fish, the friendly interactive shell
Type help for instructions on how to use fish
root@hydra ~#
The problem seems to come from this :
root@hydra ~/d/update-motd.d# bash 20-system-info
Traceback (most recent call last):
File "/etc/update-motd.d/sysinfo.py", line 67, in <module>
memperc = "%d%%" % (100-100.*meminfo['MemAvailable:']/(meminfo['MemTotal:'] or 1))
KeyError: 'MemAvailable:'
$ hydra -d -l test -p test -t 1 -s 465 smtps://YOUR-TARGET
Hydra v8.6 (c) 2017 by van Hauser/THC - Please do not use in military or secret service organizations, or for illegal purposes.
[DEBUG] Ouput color flag is 1
Hydra (http://www.thc.org/thc-hydra) starting at 2017-08-13 23:42:07
[DEBUG] cmdline: hydra -d -l test -p test -t 1 -s 465 smtps://YOUR-TARGET
[DEBUG] opt:10 argc:11 mod:smtps tgt:YOUR-TARGET port:465 misc:(null)
[INFO] several providers have implemented cracking protection, check with a small wordlist first - and stay legal!
Segmentation fault
every time show segment fault
This happens in line:
https://github.com/ldidry/dynamic-motd/blob/master/update-motd.d/sysinfo.py#L56
os.statvfs_result(f_bsize=4096, f_frsize=4096, f_blocks=6410294, f_bfree=5161825, f_bavail=4891989, f_files=1630208, f_ffree=1565195, f_favail=1565195, f_flag=4096, f_namemax=255)
os.statvfs_result(f_bsize=2048, f_frsize=2048, f_blocks=63339, f_bfree=60331, f_bavail=60331, f_files=0, f_ffree=0, f_favail=0, f_flag=4096, f_namemax=1530)
related lines in /proc/mounts
:
/dev/vda1 / ext4 rw,relatime,discard,errors=remount-ro 0 0
/dev/vda15 /boot/efi vfat rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro 0 0
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.