Skip to main content

Installation and Updates

Before Installation​

Before installation, you need to perform the following actions:

  1. Check if your IP address is correct in your Personal Account (for users with a dynamic IP address, it is necessary to change the IP address when switching to a new one) img
  2. Go to the A-Parser - Downloads tab
  3. Before downloading the required version, you should click Update to update to the latest version of A-Parser img

A-Parser Release - stable version of A-Parser, more information about new versions can be found in the news section

A-Parser Beta - intermediate version of A-Parser, which is constantly updated, more information about changes can be found on the forum in the Next Release section

A-Parser Installation​

⏩ A-Parser Video: Installation, Launch, and Update​

TODO: (next) update video

Installation on Windows​

After you complete the Before Installation stage, you need to download the program archive and unpack it into the folder you need (you can use any folder, even on the desktop)

img img

Go to the aparser folder and run aparser.exe

img

The first launch may take a long time, from 30 seconds to several minutes. After the server window appears, open http://127.0.0.1:9091/ in your browser

The default password is empty. Just click the Login button, and the A-Parser web interface will appear

Troubleshooting​

Incompatible Programs​

There are known compatibility issues with the following antivirus and programs:

  • Norton Internet Security - parser may work unstably
  • Emsisoft Anti-Malware - parser may work unstably
  • Guard Mail.ru - must be completely removed from the system
  • HTTPDebugger - interrupts A-Parser work after 2 hours of launch
Disabling Windows Indexing Service​

The indexing service can block access to files during A-Parser operation. If the parser does not start or crashes during operation, you need to check the A-Parser log aparser.log for the following entries:

IO error: ... Append: cannot write
ΠΈΠ»ΠΈ
sysopen: Permission denied

To disable the indexing service, follow these steps:

  1. open Services: Start - Run or Win + R key combination, enter services.msc
  2. in the window that opens, select Windows Search, right-click and select Properties
  3. in the properties window on the General tab, change the Startup Type to Disabled and click Apply
  4. if the Stop button is active after this - click it and stop the service img
Error While Updating Distribution​

In some cases, Windows may block access to A-Parser distribution files, in this case, the following entry will be in the aparser.log:

remove_tree failed for dist\nodejs\node_modules\...

To solve the problem:

  • make sure that there are no hung processes aparser.exe or aparser-node.exe in the task manager
  • delete the dist folder in the A-Parser directory, if Windows reports an error deleting - rename the dist folder to dist_

Installation on MacOS​

At the moment, installation on MacOS is possible using Docker

Installation on Linux​

We recommend using docker or docker-compose to install A-Parser on Linux, for classic installation follow this instruction

For convenience of downloading from the server, temporary links are implemented, in the Personal Account, click the One-time link button - using the received link, you can download the distribution once

caution

A-Parser implements its own web server, so choose a directory for installation without web access

Get a temporary download link by clicking the One-time link button, in the terminal, go to the installation directory (for example, ~/) and execute the following commands, using the received link:

wget https://a-parser.com/members/onetime/ce42f308eaa577b5/aparser-linux-x64.tar.gz
tar zxf aparser-linux-x64.tar.gz
rm -f aparser-linux-x64.tar.gz
cd aparser/
chmod +x aparser
./aparser

The first launch may take a long time, from 30 seconds to several minutes. After the server window appears, open http://127.0.0.1:9091/ in your browser. You can also go to A-Parser using the server's public IP address

The default password is empty. Just click the Login button, and the A-Parser web interface will appear

caution

Please note that by default A-Parser is available on all interfaces. We recommend setting a reliable password and restricting access using iptables if necessary.

Troubleshooting​

Sometimes the server may lack some libraries, for example:

./aparser
./aparser: error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or directory

You need to install the missing libraries:

yum -y install zlib

And then restart A-Parser:

./aparser

If no messages are displayed, this indicates a successful launch of A-Parser. You can check it with the command tail -f aparser.log

If aparser.log contains such lines:

./dist/nodejs/bin/aparser-node: /lib64/libc.so.6: version `GLIBC_2.25' not found (required by ./dist/nodejs/bin/aparser-node)
./dist/nodejs/bin/aparser-node: /lib64/libc.so.6: version `GLIBC_2.28' not found (required by ./dist/nodejs/bin/aparser-node)

then this indicates the use of an outdated version of Linux and in this case it is recommended to update the OS or use docker or docker-compose

Configuring Linux for more threads​

By default, Linux limits the number of open files and sockets to 1024 per user. To increase the limit, execute the following commands:

echo 'root soft nofile 10240' >> /etc/security/limits.conf
echo 'root hard nofile 10240' >> /etc/security/limits.conf

If you are running the parser not as root, but as another user, replace root with the username.

It is also necessary to increase the size of the ip_conntrack table:

sysctl -w net.ipv4.netfilter.ip_conntrack_max=262144
echo 'net.ipv4.netfilter.ip_conntrack_max=262144' >> /etc/sysctl.conf

If there is no iptables firewall, an error will be displayed for this command - just ignore it.

You need to log out of the terminal (ssh) and then restart A-Parser. To check the current limit, execute

ulimit -n

On some systems, it is also necessary to add the following line to the file /etc/pam.d/common-session:

session required pam_limits.so

Installation on FreeBSD​

At the moment, the Linux emulator for FreeBSD is unable to work with A-Parser stably.

File structure of the installed program​

img

The structure of the A-Parser working directory:

FileDescription
configDirectory with configuration files, it is recommended to make a backup before updating A-Parser
distDirectory with the A-Parser distribution, includes NodeJS and other additional modules
files/proxyDirectory with proxy checker settings
files/parsersDirectory contains JavaScript parser source codes created or imported by the user
logsTask execution logs
queriesDirectory with queries for parsers
resultsDirectory with parsing results
tmpTemporary directory
.htaccessApache web server configuration file to protect the working directory from web access
aparser.exe or aparserA-Parser executable file
aparser.logA-Parser work log, the main way to diagnose the current state and possible errors

img

Structure of the config directory:

FileDescription
tasksDirectory with task files (active and completed)
uniqueDirectory with unique files
config.dbMain configuration file that stores settings and presets
queue.dbFile with task queue data
scheduler.dbFile with scheduled task data
config.txtAdditional configuration file, more...
tip

To display file extensions in the Windows operating system, enable the following setting:

img

Initial setup​

img

Before starting to work with A-Parser, it is necessary to configure it for yourself:

  • Password - the default password is empty, in the Settings -> General Settings menu, you can create a new password to log in to the system.
  • Language - the ability to choose the language of the interface, news, and tips - Russian and English are available.
  • Check for updates and Update channel - notifications about the release of new parser versions. The update channel allows you to choose between stable and beta versions.

The configuration of the remaining options is described in the General Settings section.

Reset password​

You can reset the access password to the parser by running it from the command line with the -resetpassword option.

For Windows:

aparser.exe -resetpassword

For Linux:

./aparser -resetpassword

The password will be reset to empty, to log in to A-Parser, simply click Login

Updating A-Parser​

Updating via the interface​

TODO: (next) duplicated here Update A-Parser

Select the Update channel in General settings:

img

In the Tools menu, go to the Update A-Parser tab:

img

Select files for update, A-Parser will be restarted:

img

caution

Attention! Unless otherwise specified, it is sufficient to update only the executable file (aparser.exe or aparser).

Manual update on Windows​

In general, it is enough to replace the parser executable file.

  • Stop A-Parser - click Stop server
  • Download the archive from Personal account and overwrite aparser.exe
  • Run aparser.exe

Manual update on Linux​

  • Stop A-Parser - execute killall aparser in the console
  • Download the archive from Personal account and overwrite the aparser file
  • Run aparser - execute ./aparser in the console
wget https://a-parser.com/members/onetime/0d19621928c25a48/aparser.tar.gz
kill $(cat files/pid)
sleep 1
tar xzf aparser.tar.gz -O aparser/aparser > aparser
rm -f aparser.tar.gz
chmod +x aparser
./aparser

Installing one license on multiple computers​

Each license can only be used simultaneously on one PC/server. However, having one license does not prohibit installing A-Parser on multiple computers at once. In this case, A-Parser can only be launched on the PC/server whose IP is specified in the Personal account.

An example of such use can be a work PC and a home laptop: the parser can be installed on both machines, but can only be used on either the work PC or the home laptop. The number of IP changes in the Personal account is unlimited, but it is not recommended to do this more than 5 times a day, as otherwise it may be necessary to confirm the absence of fraudulent actions.

To run A-Parser simultaneously on multiple computers or servers, perform the following steps:

  1. Add additional licenses
  2. In the Personal account, go to the A-Parser - IP settings tab
  3. Enter the IP addresses of the additional computers

Installing multiple copies on one PC or server​

Each license allows you to install and run an unlimited number of copies of A-Parser simultaneously on one machine. This allows you to maximize the capabilities of powerful systems, where one copy does not use all resources and at the same time it is necessary to increase performance.

The process of installing multiple copies of the parser on one system:

  • you need to download and install each copy in a separate directory according to the standard installation instructions
  • in each copy of the parser, you need to create a config.txt file in the config directory and specify a setting like this:
bind: 0.0.0.0:9092
  • instead of 9092, specify the port on which this copy will work

After that, the parser can be launched and will be available on the specified port.

caution

Any methods of joint access, as well as renting out A-Parser, are prohibited and in case of detection the license will be canceled without refund or possibility of restoration.