Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Sat 28 May 2016, 18:21
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Network
pgprs-2.0
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 3 [40 Posts]   Goto page: 1, 2, 3 Next
Author Message
rerwin


Joined: 24 Aug 2005
Posts: 1677
Location: Maine, USA

PostPosted: Mon 25 Jan 2016, 12:41    Post subject:  pgprs-2.0
Subject description: Upgrade of original pgprs -- not to be confused with "pgprs2" by 01micko
 

Pgprs-2.0 is a reorganized and polished version of the original pgprs that employs a more standard implementation and an improved user interface. It includes a new interface script, pgprs. A clone of its "connect" logic is used in frisbee's Mobile Wireless (GPRS) function.

Now, the modem and phone number fields are replaced by drop-down lists for selection. Those lists are maintained in a new configuration file, gprs.conf, making it possible for developers and users to add device file names as they appear -- but new names should also be reported here, so they can be added officially.

Included below is an update to the connection wizard and the script that responds to connect/disconnect initiation from the network tray icon. That update is backward compatible, so can be installed even without pgprs-2.0. That "connect_updates" package contains a version for modern puppies (tahrpup, slacko) and a "legacy" version. (The correct version is installed based on the presence of the /usr/lib/gtkdialog directory.) This version of the connect_updates package is the same as that included with the package for frisbee 1.4, in that thread. Note that the connect_updates package must be installed, to allow both pgprs and frisbee to function.

Thank you to 01micko for the pgprs2 interim solution to the absence of pgprs in tahrpup, which was necessary due to the removal of the all-firmware directory on which the old pgprs depends.

Thanks, too, to Lazy Pup for his help with debugging.

Please report any problems here or by PM.
Richard
pgprs-2.0.pet
Description  Release version of pgprs-2.0, with improved behavior, inter-operation with
frisbee 1.4 and attempted compatibility with fatdog64
Requires the connect_updates package, too.
pet

 Download 
Filename  pgprs-2.0.pet 
Filesize  11.1 KB 
Downloaded  13 Time(s) 
connect_updates-20160515.pet
Description  Connect wizard and Connect/AppRun using standard interfaces
to pgprs and frisbee
Pdiag updates
pet

 Download 
Filename  connect_updates-20160515.pet 
Filesize  12.58 KB 
Downloaded  11 Time(s) 

Last edited by rerwin on Thu 19 May 2016, 14:54; edited 17 times in total
Back to top
View user's profile Send private message 
watchdog

Joined: 28 Sep 2012
Posts: 1016

PostPosted: Mon 25 Jan 2016, 15:30    Post subject:  

Working here in slacko 6.3.0 32 bit! Firewall setup required. I'm posting by a 3G usb modem dongle connection:

Code:
Attempting connection through /dev/ttyUSB0 to APN internet.wind...

Press CTRL-C to close the connection at any stage!
defining PDP context...

AT
OK
AT
OK
AT+CGDCONT=1,"IP","internet.wind"
OK
ATH
OK
ATE1
OK
AT+CSQ
waiting for connect...

+CSQ: 15,99

OK
ATD*99***1#
CONNECT
Connected.
If the following ppp negotiations fail,

try restarting the phone.

Script chat -v -f /etc/ppp/chatscripts/gprs-connect-chat finished (pid 24221), status = 0x0
Serial connection established.
using channel 1
Using interface ppp0
Connect: ppp0 <--> /dev/ttyUSB0
Warning - secret file /etc/ppp/pap-secrets has world and/or group access
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0xfaab41c6> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0x0 <asyncmap 0x0> <auth chap MD5> <magic 0xf43d5a> <pcomp> <accomp>]
No auth is possible
sent [LCP ConfRej id=0x0 <auth chap MD5>]
rcvd [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0xfaab41c6> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0xf43d5a> <pcomp> <accomp>]
sent [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0xf43d5a> <pcomp> <accomp>]
sent [LCP EchoReq id=0x0 magic=0xfaab41c6]
kernel does not support PPP filtering
sent [IPCP ConfReq id=0x1 <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns2 0.0.0.0>]
rcvd [LCP DiscReq id=0x2 magic=0xf43d5a]
rcvd [LCP EchoRep id=0x0 magic=0xf43d5a fa ab 41 c6]
rcvd [IPCP ConfNak id=0x1 <ms-dns1 0.0.0.0> <ms-dns2 0.0.0.0>]
sent [IPCP ConfReq id=0x2 <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns2 0.0.0.0>]
rcvd [IPCP ConfReq id=0x0]
sent [IPCP ConfNak id=0x0 <addr 10.0.0.1>]
rcvd [IPCP ConfNak id=0x2 <addr 10.43.65.20> <ms-dns1 193.70.152.25> <ms-dns2 212.52.97.25>]
sent [IPCP ConfReq id=0x3 <addr 10.43.65.20> <ms-dns1 193.70.152.25> <ms-dns2 212.52.97.25>]
rcvd [IPCP ConfReq id=0x1]
sent [IPCP ConfAck id=0x1]
rcvd [IPCP ConfAck id=0x3 <addr 10.43.65.20> <ms-dns1 193.70.152.25> <ms-dns2 212.52.97.25>]
local  IP address 10.43.65.20
remote IP address 10.0.0.1
primary   DNS address 193.70.152.25
secondary DNS address 212.52.97.25


/etc/pgprs.conf:

Code:
GPRSDEV=/dev/ttyUSB0
GPRSNBR=*99***1#
GPRSAPN=internet.wind
GPRSPIN=
GPRSUSER=
GPRSPAPONLY=false
GPRSNBRS='*99# #777 *99***1# *99***2# *99***3# *99***4#'
GPRSOTHERDEVS='/dev/ircomm* /dev/ttyUB* /dev/ttyS0 /dev/ttyS1'


Problems with connect-updates: after closing the 3G connection I was not able to setup the eth0 connection again by the internet connection wizard. I removed connect-updates, restarted X and now I'm with eth0 again.
Back to top
View user's profile Send private message 
rerwin


Joined: 24 Aug 2005
Posts: 1677
Location: Maine, USA

PostPosted: Tue 26 Jan 2016, 14:11    Post subject:  

watchdog,
Thank you very much, for trying the packages, showing us what success looks like, and reporting the problem.
watchdog wrote:
Problems with connect-updates: after closing the 3G connection I was not able to setup the eth0 connection again by the internet connection wizard. I removed connect-updates, restarted X and now I'm with eth0 again.
To work the problem, I need more details. First, are there any connectwizard/pgprs error messages at the end of file /etc/xerrs.log? Assuming there are none, please tell me what you did and saw after clicking the "Disconnect" button in the connection window.

Note that this version of pgprs disables the other networks, to prevent the network controller (dhcpcd) from interrupting the connection. 01micko has recommended that to me.

Thanks for your help.
Richard
Back to top
View user's profile Send private message 
watchdog

Joined: 28 Sep 2012
Posts: 1016

PostPosted: Tue 26 Jan 2016, 15:43    Post subject:  

rerwin wrote:

end of file /etc/xerrs.log? Assuming there are none, please tell me what you did and saw after clicking the "Disconnect" button in the connection window.


After disconnecting the mobile modem clicking on Connect on the desktop does not open the default connection manager which is Network Wizard for me. Network Wizard does not work from Menu-Setup-Internet Connection Wizard, too.

Quote:
Note that this version of pgprs disables the other networks, to prevent the network controller (dhcpcd) from interrupting the connection. 01micko has recommended that to me.


Yes, a running dhcpd updates resolv.conf which is not good but when you close pgprs2 you might be able to setup eth0 again.
Back to top
View user's profile Send private message 
rerwin


Joined: 24 Aug 2005
Posts: 1677
Location: Maine, USA

PostPosted: Wed 27 Jan 2016, 00:28    Post subject:  

A-hah! And oops.

The clue is an error message in xerrs.log. It is a bug I fixed in my test setup but did not fully implement in the development copy. (The problem is that the command, cut -f 2 -d \", confuses the parser inside `...` but is OK in $(...) -- both should execute the command.)

The corrected package is now uploaded above. Thank you to all three who downloaded the original -- please replace your copy with the new connect_updates package.
R
Back to top
View user's profile Send private message 
watchdog

Joined: 28 Sep 2012
Posts: 1016

PostPosted: Wed 27 Jan 2016, 01:38    Post subject:  

In someway it works but there is a bug. I disconnected eth0 right-clicking the network-tray down-right and connected by pgprs2 and the mobile modem after installing the new connect_updates. The connection was successfull and I was fully online but the window said "connection unsuccessfull". I attach screenshot. There was not a disconnect button. I clicked OK and the log-window closed and then I launched pgprs2 again from Menu-Network: it detected a connection alive and offered to disconnect. I disconnected and was able to setup eth0 again.
screenshot.png
Description 
png

 Download 
Filename  screenshot.png 
Filesize  134.2 KB 
Downloaded  153 Time(s) 
Back to top
View user's profile Send private message 
rerwin


Joined: 24 Aug 2005
Posts: 1677
Location: Maine, USA

PostPosted: Wed 27 Jan 2016, 14:28    Post subject:  

watchdog wrote:
The connection was successful and I was fully online but the window said "connection unsuccessful". I attach screenshot. There was not a disconnect button.
Thanks for that report. This is the area where I am dependent on your help. The test for success checks for a file named /var/run/ppp-gprs.pid. When you are connected through pgprs, please check for that file or something similar ( /var/run/ppp*). If the file is present, that suggests that pgprs is not waiting long enough for the ppp daemon to get started and create the file. If there is only another, similar, file, please tell me its name.

Maybe I need to change the 'sleep 1' (in /usr/local/pgprs/pgprs-connect) to a loop to keep checking for, say, 10 seconds.
R
Back to top
View user's profile Send private message 
watchdog

Joined: 28 Sep 2012
Posts: 1016

PostPosted: Wed 27 Jan 2016, 17:00    Post subject:  

I can't replicate the first behaviour: I have reinstalled connect_updates and it's now properly working (three attempts to replicate the error...). In /var/run there are ppp-gprs.pid and ppp0.pid. Maybe a "sleep 5" before checking success of the connection could solve a possible bad start of the script which is indeed very fast. It's solved for me. Many thanks.
Back to top
View user's profile Send private message 
rerwin


Joined: 24 Aug 2005
Posts: 1677
Location: Maine, USA

PostPosted: Wed 27 Jan 2016, 21:16    Post subject:  

That is good news. I suspect that connecting the first time since boot requires extra time for the ppp components to load from disk or elsewhere in RAM, causing a small delay in the appearance of the file used as the indicator of a connection.

To address that, I have added a 5-second loop that tests every second until the file appears, or stops trying. Uploaded as "20160127"
R

EDIT: I have now restored the connect_updates package inadvertently replaced by the updated pgprs.
Back to top
View user's profile Send private message 
rerwin


Joined: 24 Aug 2005
Posts: 1677
Location: Maine, USA

PostPosted: Wed 17 Feb 2016, 21:17    Post subject:  

I admit that the 20160127 version of pgprs is defective, in that it may not start after the initial use of it. I have replaced it, above, with a corrected version, 20160214-beta. It also should work without interfering with the upcoming frisbee 1.4 (currently 1.3.5 beta), and vice versa.

I also updated the connect_updates package to support the new frisbee and to include an updated script (get_modem_alternate_device) from frisbee that is actually independent of frisbee, because it is also used by pupdial.
R
Back to top
View user's profile Send private message 
watchdog

Joined: 28 Sep 2012
Posts: 1016

PostPosted: Thu 18 Feb 2016, 04:28    Post subject:  

Hi, rerwin.
I'm posting from the updated pgprs2 and my internet usb dongle in slacko 6.3.0 but I have had to manually write nameservers in /etc/resolv.conf which is not updated after successfull connection. I also tried the default frisbee in slacko 6.3.0 but it does not detect the dev device.
Back to top
View user's profile Send private message 
LazY Puppy


Joined: 21 Nov 2014
Posts: 1069
Location: Germany

PostPosted: Thu 18 Feb 2016, 17:53    Post subject:  

Hi.

I had tried the new packages a few moments ago.

Still do NOT get this to work with my GPRS USB Modem (tested in tahr 602 and 605).

After installing the packages nothing happens when choosing GPRS Wireless Modem to use to connect to the web. No GUI appears to setup the APN and stuff.

Frisbee does NOT detect the USB Modem (by the earlier PGPRS packges it does) - DialUp (2g/3g) does detect the USB Modem, but is unable to do a connection.

When I'm entering pgprs --connect into a terminal it hangs afterwards - no further terminal output is appearing.

When I'm installing my personal PGPRS package afterwards it even won't also connect to the web if your packages has been installed first (need to do a reboot to get internet connection using my personal PGPRS package).

Usually in all my newer Puppies (above Precise) I just install my personal PGPRS package and am able to connect to the web immediately.

I'm still NOT convinced for the replacement of the original PGPRS package as I can't use it (and am assuming there are lots of users that even can't use it too)!

I fear for the future Puppies they even won't let me connect to the web using my personal PGPRS package - which will make me then STOP using Puppy Linux!

One (person like ME) can't use a Puppy Linux without to have internet access to download some software from the PPM repositories.

It's a SHAME for all the Puppy Builders (Woof CE) to replace a nice working and easy to use feature by a new but still NOT working feature!!!

Woof CE seems to have some really nice improvements etc.pp. in some parts, but this CRAP!

REALLY CRAP!

EDIT:

Now tested this also with tahr64 605 (fdrv sfs loaded): no differences!

_________________
RSH

T.O.P.L.E.S.S. - the Multi-Language Puppy Linux Wrapper.
Just use one single frugal install of a Puppy Linux (32 & 64bit) to be personalised in many different ways.
Back to top
View user's profile Send private message 
rerwin


Joined: 24 Aug 2005
Posts: 1677
Location: Maine, USA

PostPosted: Fri 19 Feb 2016, 20:06    Post subject:  

watchdog,
Since "pgprs2" is 01micko;s upgrade of the original pgprs, I think you should contact him about this. I understand that "pppd" handles the resolv.conf business. Maybe slacko interferes with that.

But if you still have that problem with my version that I intend to be "pgprs-2.0" once we get past beta testing, please report that here.
R
Back to top
View user's profile Send private message 
rerwin


Joined: 24 Aug 2005
Posts: 1677
Location: Maine, USA

PostPosted: Fri 19 Feb 2016, 20:35    Post subject:  

LazY Puppy,
Thanks for continuing your attempts to get my pgprs to work for you. While we were working the problem via PMs, you mentioned that you install the pet package by extracting its files. If you do not run the pinstall.sh script in the package, the file, /etc/gprs.conf, will not get removed. That could be why pgprs refuses to start. I'll explain.

The 20160214 package changes the content of gprs.conf, adding an essential parameter. If that parameter is missing, pgprs will exit without explanation. The pinstall.sh script removes the old gprs.conf to ensure that one with the correct content is created. So, please delete /etc/gprs,conf before running pgprs the first time after installing. Note that the script also removes components of the old pgprs, so that only the new one is present. But leaving the old pgprs in place should not cause problems other than showing confusing menu options.
R
Back to top
View user's profile Send private message 
LazY Puppy


Joined: 21 Nov 2014
Posts: 1069
Location: Germany

PostPosted: Sat 20 Feb 2016, 00:02    Post subject:  

rerwin wrote:
LazY Puppy,
Thanks for continuing your attempts to get my pgprs to work for you. While we were working the problem via PMs, you mentioned that you install the pet package by extracting its files. If you do not run the pinstall.sh script in the package, the file, /etc/gprs.conf, will not get removed. That could be why pgprs refuses to start. I'll explain.

The 20160214 package changes the content of gprs.conf, adding an essential parameter. If that parameter is missing, pgprs will exit without explanation. The pinstall.sh script removes the old gprs.conf to ensure that one with the correct content is created. So, please delete /etc/gprs,conf before running pgprs the first time after installing. Note that the script also removes components of the old pgprs, so that only the new one is present. But leaving the old pgprs in place should not cause problems other than showing confusing menu options.
R

I installed just by clicking the .pet files - nothing else!

As I wrote: when typing pgprs --connect into a terminal it hangs afterwards. The terminal is locked then by pgprs. Since there was no option to setup my APN and stuff, I assume that's why it hangs/the terminal is locked then.

So how should/could PGPRS do a successful connection if it doesn't know anything about my APN and stuff?????????????????????

Where is the part to enter this in the new pgprs?????????????????????

It doesn't make any sense to have a pgprs connect entry in menu without having option to setup APN and stuff first. Usually in internet connection wizard a GUI appears to do that after clicking the wireless gprs modem button. And in previously built in pgprs package there was also a menu entry to setup APN and stuff.

In your pgprs package this GUI doesn't appear on the screen - as no gui at all will give option to setup APN and stuff.

If I close the terminal window and try to type again pgprs --connect into a new opened terminal it tells me that pgprs (or probably just gprs) is already running. It recommended the use of the runnung pgprs/gprs then.

By the way: I forgot to mention that frisbee is recognizing the USB Modem after a refresh in tahr64 605 with the fdrv sfs loaded, though -as in all my previous testings- exit code 8. No connection possible.

And just as a side note: my criticism is about the Woof CE idea in that special case - not about any of your codes or efforts.

_________________
RSH

T.O.P.L.E.S.S. - the Multi-Language Puppy Linux Wrapper.
Just use one single frugal install of a Puppy Linux (32 & 64bit) to be personalised in many different ways.
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 3 [40 Posts]   Goto page: 1, 2, 3 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Network
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0703s ][ Queries: 12 (0.0055s) ][ GZIP on ]