JDownloader Community - Appwork GmbH
 

Notices

Reply
 
Thread Tools Display Modes
  #2221  
Old 04.06.2022, 18:01
Mydgard Mydgard is offline
Fibre Channel User
 
Join Date: Jan 2011
Location: Germany
Posts: 115
Default

[QUOTE=mgpai;503641]
You can use this to get the count of links which for which hashcheck has been disabled

4657 Links ...

Testet a small file, no crc check occured ... so it it worked

Thanx again.

Last edited by Mydgard; 04.06.2022 at 18:08.
Reply With Quote
  #2222  
Old 04.06.2022, 18:01
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,533
Default

Quote:
Originally Posted by Mydgard View Post
@mgpai: will i get a end message or something similar? have 10877 links in jd2 actual ...

Not sure how long it will take to run?
I have tested only on list with few links, so not sure how long it will take for 10k+ links. How many of those are unfinished links? If in doubt, I can modify the script to display a message at the end. You will have to restart JD (to abort the current script if it is running) and add the new script and run it again.
Reply With Quote
  #2223  
Old 04.06.2022, 18:03
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,533
Default

Quote:
Originally Posted by Mydgard View Post
4657 Links ...
Guess all good then.
Reply With Quote
  #2224  
Old 04.06.2022, 18:16
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,533
Default

Quote:
Originally Posted by StefanM View Post
... or could be written.
Code:
/*
    Export link info
    Trigger : Downloadlist contextmenu button pressed
    Customizze downloadlist context menu > Add a noew "Eventscripter Trigger" button > Rename it to "Export link info"
*/

if (name == "Export link info") {
    var file = JD_HOME + "/" + Date.now() + ".tsv";
    var data = [];

    dlSelection.links.forEach(function(link) {
        data.push([getPath(link.downloadPath).extension, link.name, link.bytesLoaded, link.downloadPath, link.url].join("\t"));
    })

    if (data.length) {
        writeFile(file, data.join("\r\n"), true);
    }
}
Reply With Quote
  #2225  
Old 04.06.2022, 18:34
Mydgard Mydgard is offline
Fibre Channel User
 
Join Date: Jan 2011
Location: Germany
Posts: 115
Default

@mgpai: All unfinished ... why should i hold finished links in jd2? Before you may ask: yes all those links are around 22,91 TB of space i don't have actual ... some of them are somewhat older Approx 17,5 TB are RG links ...

Last edited by Mydgard; 04.06.2022 at 18:36.
Reply With Quote
  #2226  
Old 04.06.2022, 18:38
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,533
Default

Quote:
Originally Posted by Mydgard View Post
@mgpai: All unfinished ... why should i hold finished links in jd2?
Asked because many users leave finished links in the list to know if a file has been downloaded before and avoid downloading it again. There are users who have millions (not exaggerating) of finished links in the download list.
Reply With Quote
  #2227  
Old 04.06.2022, 21:41
Mydgard Mydgard is offline
Fibre Channel User
 
Join Date: Jan 2011
Location: Germany
Posts: 115
Default

Okay? One Page ago you told someone he could use a dupe check within existing links, tried to google that, but ... even as dupe check in link grabber is active i have dupes in my list ... several times i downloaded a file and somewhere in the list it shows "mirror is loading" exact same name same file size ... dunno why jd2 didn't showed the new link in red to tell me it is still in list ...

Any chance to give me fix script to find those dupes?
Reply With Quote
  #2228  
Old 05.06.2022, 09:55
slcf2003 slcf2003 is offline
Modem User
 
Join Date: Nov 2021
Posts: 2
Default

Hi mgpai,

I'm running my JD on a remote vps as a download station, and I ssh to the vps and upload the downloaded file to a transfer site called oshi.at using the command
Code:
curl -T /path/to/file **External links are only visible to Support Staff**
Could you make a script for me to achieve the above task, so that I don't have to do the ssh every time? I would like the script to be triggered when the download task is done, and also when the file's extention is rar or zip. I don't know if I'm able to use the curl or call a bash script in the JD's event scripter.

Thank you.
Reply With Quote
  #2229  
Old 05.06.2022, 15:58
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 79,343
Default

@slcf2003: you should also explain what to do then for example what to do with response, most likely it will contain a download URL then?
Quote:
Originally Posted by slcf2003 View Post
I don't know if I'm able to use the curl or call a bash script in the JD's event scripter.
Yes you can, see/search this thread, there are many examples how to execute external tool/script.
__________________
JD-Dev & Server-Admin
Reply With Quote
  #2230  
Old 05.06.2022, 16:02
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 79,343
Default

Quote:
Originally Posted by Mydgard View Post
dunno why jd2 didn't showed the new link in red to tell me it is still in list ...
*Already in list* only works on full URL or internal linkID. When URL changes, then this duplicate detection won't work.

Quote:
Originally Posted by Mydgard View Post
check in link grabber is active i have dupes in my list ... several times i downloaded a file and somewhere in the list it shows "mirror is loading" exact same name same file size ...
Mirror is not Duplicate. Mirror just means JDownloader detects a file *as same* based on your setup mirror conditions (eg filename and filesize). Duplicate is the exact same link

Quote:
Originally Posted by Mydgard View Post
Any chance to give me fix script to find those dupes?
I'm sure mgpai can help with this, but you will have to decide the condition. because filename alone is unsafe. also you have to decide if you only want to check against safe or unsafe filename/filesize. Safe = JDownloader will use the filename/filesize for downloading (eg information provided by an api) while unsafe means that filename or size can still change.

Maybe you should try to do a teamviewer session with mgpai(or us) and explain him what you want to achieve, so he/us can take a look at the *situation* and provide better help!
__________________
JD-Dev & Server-Admin

Last edited by Jiaz; 05.06.2022 at 16:15.
Reply With Quote
  #2231  
Old 06.06.2022, 22:34
Tomrich Tomrich is offline
Wind Gust
 
Join Date: Aug 2020
Posts: 43
Default

Quote:
Originally Posted by Jiaz View Post
@Tomrich: I would recommend to check/fix the installation, see **External links are only visible to Support Staff**...
then install the eventscripter via webinterface , hit the button, and then restart JDownloader
i tried this but after restart or reboot i can't connect via myjdownloader. can i do the login again? the only way i know is this https://support.jdownloader.org/Know...bedded-devices but thats for installing jdownloader.
Reply With Quote
  #2232  
Old 06.06.2022, 22:37
flowlapache flowlapache is offline
DSL Light User
 
Join Date: Oct 2016
Posts: 31
Default parse a url from a board needing login

Hi ! I try to make a script to let JD to search some direct links from a board where it's needed to be logged in to view those direct links; but I can't fin dexample...Could you help me please? thanks
Reply With Quote
  #2233  
Old 07.06.2022, 07:36
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,533
Default

Quote:
Originally Posted by flowlapache View Post
Hi ! I try to make a script to let JD to search some direct links from a board where it's needed to be logged in to view those direct links; but I can't fin dexample...Could you help me please? thanks
Script
Reply With Quote
  #2234  
Old 07.06.2022, 19:29
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 79,343
Default

@Tomrich: close JDownloader/kill running process and the same command line can be used
Quote:
java -jar JDownloader.jar -norestart
in case your MyJDownloader logins are missing/wrong, JDownloader will ask for them again
else contact us via support@jdownloader.org and we can take a look at it together
__________________
JD-Dev & Server-Admin
Reply With Quote
  #2235  
Old 09.06.2022, 09:47
xefeg xefeg is offline
JD Alpha
 
Join Date: Oct 2019
Posts: 24
Default

Script Request - Split larger than x_size and move them to folder

1. Download Files (extensions are usually, .rar .zip .exe .dmg .apk)
2. Download Finished (Extraction of .rar or .zip is not required)
3. If filesize is smaller than 999 MB move to folder A
4. Else, Split Files into parts to a certain size, usually 999 MB parts (Size999.part1.rar, Size999.part2.rar)
5. Move split files to folder A

Last edited by xefeg; 09.06.2022 at 10:18.
Reply With Quote
  #2236  
Old 09.06.2022, 10:14
xefeg xefeg is offline
JD Alpha
 
Join Date: Oct 2019
Posts: 24
Default

Script - Move downloaded files from specific folder to folder A

Using Packagizer, I sort my files based on the host it downloaded. Here is what I need.

1. Download from Google.com
2. Folder for Google.com is Folder A using Packagizer
3. Move files from Folder A to Folder B

Solution is here by mgpai
https://board.jdownloader.org/showpo...6&postcount=35

Last edited by xefeg; 09.06.2022 at 13:52. Reason: Request filled and link to the script
Reply With Quote
  #2237  
Old 09.06.2022, 12:29
StefanM's Avatar
StefanM StefanM is offline
JD VIP
 
Join Date: Oct 2020
Posts: 484
Default Script to add (random) delays between requests and/or downloads

@mgpai or anyone who can help

NEW REQUEST
Adding (random) delays between requests and/or downloads


Many webpages detect too many requests/downloads in a short period of time and then block the user IP for some time.
That's why with some Download Managers the user can define delays between requests/downloads.

If possible, a script for this would really be appreciated.

A possible URS would look like this

A) Timer definition (optional!)
The user can either define a fixed delay in seconds. Optional (not that important): User can define a random delay between X and Y seconds.
Note: To make things not too complicated, a script with a fixed delay, e.g. 2 seconds, would be fine with me.


B) (Random) delay while grabbing links
Link grabbing must be reduced to only one request at a time. After a request has been sent by JD, the 'programmed' timer will start.

Once the timer has run out, the next request will be sent.


C) (Random) delay while downloading
Max. simultaneous downloads should work as usual. Let's assume the limit was set to 3:

JD should start with the first download. At the same time the 'programmed' timer will start.

Once the timer has run out, the second download will be started. Again the 'programmed' timer will start. Once the timer has run out, the third download will be started. Once again, the 'programmed' timer will start.

If one of those three downloads has been finished, a new download will not be started before the timer has run out.



PS: I filed this as a feature request first, but it was declined. At the same time pspzockerscene recommended to ask for such a script here.
Reply With Quote
  #2238  
Old 09.06.2022, 12:44
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 79,343
Default

Quote:
Originally Posted by StefanM View Post
Many webpages detect too many requests/downloads in a short period of time and then block the user IP for some time.
That's why with some Download Managers the user can define delays between requests/downloads.
Please see my comment here https://board.jdownloader.org/showthread.php?t=90790
A.) you can use sleep command in scripts
B.) @mgpai: you could use packagizer hook here to add sleep/wait in linkcrawler
C.) @StefanM: you can add sleep/wait before/after a download start/finish but only on download/link level NOT on request level
@mgpai: synchronous script with dummy script
Quote:
sleep=10000;
while(sleep>0 && !link.isAborting())
sleep(1000)
sleep=sleep-1000;
I will add new DownloadLinkSandbox.isAborting() method for this
__________________
JD-Dev & Server-Admin

Last edited by pspzockerscene; 09.06.2022 at 17:28. Reason: Fixed typo
Reply With Quote
  #2239  
Old 09.06.2022, 13:06
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 79,343
Default

Quote:
Originally Posted by xefeg View Post
4. Else, Split Files into parts to a certain size, usually 999 MB parts (Size999.part1.rar, Size999.part2.rar)
5. Move split files to folder A
Why the need to split them? Please know that this will most likely break (manual) extraction of multipart archives when a single part is larger and split. for example: first file might be Size999.part1.part1.rar, Size999part1.part2.rar and second file Size999.part2.rar
__________________
JD-Dev & Server-Admin
Reply With Quote
  #2240  
Old 09.06.2022, 13:11
xefeg xefeg is offline
JD Alpha
 
Join Date: Oct 2019
Posts: 24
Default

Quote:
Originally Posted by Jiaz View Post
Why the need to split them? Please know that this will most likely break (manual) extraction of multipart archives when a single part is larger and split. for example: first file might be Size999.part1.part1.rar, Size999part1.part2.rar and second file Size999.part2.rar
If a 2GB file is downloaded and has a folder. Will it be able to split the folder which contants the file into parts? lets say 900MB.part1.rar....?
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +2. The time now is 13:57.
Provided By AppWork GmbH | Privacy | Imprint
Parts of the Design are used from Kirsch designed by Andrew & Austin
Powered by vBulletin® Version 3.8.10 Beta 1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.