Sponsored Content
Top Forums Shell Programming and Scripting Log of lost internet connections Post 303028683 by drew77 on Saturday 12th of January 2019 02:45:38 PM
Old 01-12-2019
Log of lost internet connections

I am having a big problem with lost internet connections with my DSL.

I would like to create a log to be able to show the technician when he comes next week.

I would like for it to only log pings that generate 100% packet loss. Thanks..

This script generates all ping attempts including successful ones.

Code:
while true; do

date >> Internet_Connection_Log.txt
echo >> Internet_Connection_Log.txt
ping  47.182.239.232 -c 1 >> Internet_Connection_Log.txt
echo >> Internet_Connection_Log.txt
sleep 180
done

Moderator's Comments:
Mod Comment edit bybakunin: Please use CODE-tags when posting code, data or terminal output. It is not only in the rules, it is the sensible thing to do. Thank you.

Last edited by bakunin; 01-12-2019 at 06:03 PM..
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

dsl connections lost when attempting to retrieve mail from my server.

suse linux 6.4 im running and i have port 110 for pop and smtp open, i have set up some email addresses for my friends, but they recieve errors saying that relaying is denied. i know this is to prevent spamming software from using my domain to send spam, but how do i let my users send their mail?... (6 Replies)
Discussion started by: norsk hedensk
6 Replies

2. UNIX for Advanced & Expert Users

combining two internet connections

hey guys Do you guys know of a good way that I can combine and load balance my 2 Internet connections using a Linux or Bsd box? Would LVS be able to do this? Thanks in advance (1 Reply)
Discussion started by: arya6000
1 Replies

3. IP Networking

Lost Connectivity to the Internet

I'm running FreeBSD 6.2 and suddenly lost connectivity to the net. After unplugging the router and checking all the connections I could find nothing wrong. All the driver software seems to be intact. I thought I would remove the driver software and restore it. However, when I go to root and type ... (5 Replies)
Discussion started by: Aaron Van
5 Replies

4. IP Networking

Aggregate two internet connections

Hi I have a question related to load balancing.I have two separate internet connections with 2Mbps speed and i would like to aggregate this two connections intro one connection with 4Mbps.Is it possible to do that, to put a Linux or Unix machine as a gateway?I read some stuff to split the... (3 Replies)
Discussion started by: tafil
3 Replies

5. Ubuntu

Lost the log off, power down, etc. icon!

I had a purge of applications on my Ubuntu 8.10 install and lost the above mentioned icon from the toolbar, yes I know I should have left it alone! I have managed to find and install a shutdown icon and a separate shutdown, restart,etc icon uing the synaptic package manager but they are not the... (0 Replies)
Discussion started by: TonyFullerMalv
0 Replies

6. Windows & DOS: Issues & Discussions

42 UDP internet connections

First I had a problem: My internet was slow, now I know why, I have opened 42 connections to internet. What can I do? Thanks, YourDestinity (1 Reply)
Discussion started by: YourDestinity
1 Replies

7. IP Networking

Bonding Internet Connections

I’m familiar with load balancing.. but Is it possible to actually bond multiple DSL lines together? I hear of ways to bond using MLPPP but that requires support from an ISP. Is there a way to actually bond without support from my ISP, or use say a cable modem and a DSL line together for faster... (0 Replies)
Discussion started by: harley313
0 Replies

8. Red Hat

How to Multiple internet connections manage into a single connection.

Dear all, Hope you are all fine & enjoying your good health. Look at this equation 1+1+1=3 So simple I just want to say that I have three internet connections of 1mb, 1mb & 1mb but I can use only 1mb connection at a time & other two connections are useless for me. But now I want to make all... (0 Replies)
Discussion started by: saqlain.bashir
0 Replies

9. IP Networking

All incoming connections ips LOG

How to make a log that will log all ips that connect to the server or send packets? And how to block an ip that make packets flood and try to DDoS? Thanks. (1 Reply)
Discussion started by: [xEF]Danger
1 Replies
ACCOUNTING(1)                                                         SMPPPD                                                         ACCOUNTING(1)

NAME
accounting - calculates statistics about your internet connections DESCRIPTION
accounting is a simple program to calculate statistics about your internet dial-up connections that are started and stopped by either ifup and ifdown or by a frontend to smpppd like cinternet , qinternet or kinternet. OPTIONS
These options are recognized by accounting. If a long option shows an argument as mandatory, then it is mandatory for the equivalent short option also. -l, --last=NUM Only consider the last NUM connections. -a, --after=DATE Only consider connections started after DATE. DATE is a date with optional time in ISO 8601 format, e.g. `2002-12-24 20:15:00'. Note that a date without time is treated as if the time is 00:00:00. Hence connections started on the specified date are consid- ered. -b, --before=DATE Only consider connections started before DATE. -u, --user=USER Only consider connections started by user USER. --this-year Only consider connections started this year. --last-year Only consider connections started last year. --this-month Only consider connections started this month. --last-month Only consider connections started last month. --this-week Only consider connections started this week. --last-week Only consider connections started last week. --today Only consider connections started today. --yesterday Only consider connections started yesterday. --per-year Show summaries on a per year basis. --per-month Show summaries on a per month basis. --per-week Show summaries on a per week basis. --per-day Show summaries on a per day basis. -c, --connections Only list the connections but do not show provider statistics. -p, --providers Do not list the connections only show the provider statistics. --connection-format=FORMAT The names of the columns to print in the connection list. The names must be separated by a comma. Known column names are time, type, provider, user, status, duration, rx, tx, rxtx, averx, avetx and averxtx. Each name may be appended by a colon and a number indicating the width for the column, e.g. provider:25. The value will not be truncated if the width is too small. --provider-format=FORMAT The names of the columns to print in the provider list equivalent to the --connection-format option. Known column names are provider, number, duration, rx, tx, rxtx, aveduration, averx, avetx and averxtx. --local Display all dates in local time. Also interpret dates on the command line in local time. This is the default. --utc Display all dates in UTC. Also interpret dates on the command line in UTC. --script[=STYLE] Format output for script. Known styles are c and sh. -f, --file=NAME Use a different file with accounting information. --report-errors Report erros in the accounting file. --version Show program version and exit. --help Show help information and exit. NOTES
All informations are only obtained through the accounting log. Hence the informations, esp. the data volume, of currently active connec- tions is not accurate. If you want the know the status of a connection, use ifstatus or a frontend to smpppd like cinternet , qinternet or kinternet instead. The user field is empty for connections started by a remote frontend of smpppd. BUGS
Not yet implemented for ISDN (ippp). FILES
/var/log/smpppd/accounting.log File containing accounting information. SEE ALSO
kinternet, qinternet, cinternet(1), smpppd(8), smpppd-ifcfg(8). AUTHOR
Arvin Schnell <arvin@suse.de> SuSE December 2002 ACCOUNTING(1)
All times are GMT -4. The time now is 07:36 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy