CMDCommand · run as root on the server · foreign family
urbestack-foreign-import
First published 3 Oct 2026
0.1.0Unchanged since publicationUsage
6 forms# urbestack-foreign-import --file /path/archive.tar.gz [--as NAME] [--owner RESELLER] [--paths rewrite|leave] [--default-mailbox LOCAL] [--skip-database NAME ...] [--job ID]# urbestack-foreign-import --file /path/archive.tar.gz --inspect [--as NAME] [--owner RESELLER] [--default-mailbox LOCAL] [--skip-database NAME ...]# urbestack-foreign-import --scan /root/import | --scan /path/archive.tar.gz [--owner RESELLER]# urbestack-foreign-import --list [--owner RESELLER]# urbestack-foreign-import --archive ID --show | --inspect [choices] | --queue [choices] | [--job ID]# urbestack-foreign-import --forget ID [--owner RESELLER]Description
From the command's --help outputImports a hosting account into UrbeStack from a pkgacct archive or a full backup downloaded from the customer's panel on the source server. Use --file to specify the archive. The import keeps the original account name unless you specify --as NAME. It preserves a SHA-512 crypt login password. The web interface replaces the hash on the first successful login, while SFTP and FTP continue to accept the same password. Use --file with --inspect to read the archive metadata without unpacking the archive or creating the account. The report shows the account that would be created, missing PHP versions or services such as MariaDB and FTP, account name, domain and database conflicts, and anything the import would drop or leave behind. Blocking conflicts and missing requirements stop the import before it creates the account. If software must be installed first, the check gives the installation order. The import restores domains, subdomains and aliases with their document roots and PHP versions. It runs tar as the customer to unpack the home directory. By default, --paths rewrite replaces references to the old home path in .htaccess, .user.ini and php.ini. Use --paths leave to keep those references. The import lists any other files that refer to the old home path. It restores DNS zone records and updates records that point to the source server's IP address to point to this server's IP address. The import loads database dumps into MariaDB as supplied and restores database users and grants. Repeat --skip-database NAME up to 100 times to omit databases, for example when a name is already taken. The import skips each named dump and omits users associated only with skipped databases. The inspection, job log and import result identify the skipped databases. The import restores unexpired certificates that cover their domains. UrbeStack treats free certificates as its own and paid certificates as customer-provided. It also restores FTP accounts, SSH keys and cron jobs. If FTP is unavailable, it reports the skipped FTP accounts. The import restores mailboxes with their password hashes and quotas, forwarders, the default email address, autoresponders, DKIM keys under their original selectors, and webmail address books and identities. It applies the account's filters to every domain and restores each mailbox's own filters. Filter conversion uses heuristics and reports any filters it skips. It applies the account's hourly mail limit separately to each domain and routes mail for domains with external MX records to those servers. The account's mailbox at the top of mail/ becomes an ordinary mailbox under the main domain if the destination email address is free. It uses <name>@<main domain> by default. Use --default-mailbox LOCAL to set a different local part. The import logs each step, updates the job's progress percentage as steps finish and runs one rebuild at the end. It stops at the first failure, reports the steps that completed and leaves any partially imported account in place. Use --job ID to record progress under an existing job. A direct import creates its own job by default. Use --owner RESELLER to import under a reseller. The archive must belong to the reseller and be inside their home directory, and the new account must fit within the reseller's limits. Reseller paths are relative to the root of their home directory, and resellers see only their own archive entries. Use --scan with a directory to track its .tar.gz and .tgz archives in the Import section. The scan skips hidden files and symbolic links. A change in file size or modification time clears the saved inspection and keeps the import choices. Missing files are removed from the list, with entries kept for imported archives and imports that are queued or running. Use --scan with a file to add that archive wherever it is within the allowed paths. The import.dir setting sets the default import directory, which falls back to /root/import. For a reseller, the default is /import relative to their home directory. Use --list to see the tracked archives and their states. A new archive is awaiting inspection. A read archive shows the inspection counts and proposed account. An importing archive shows the job, current step and progress percentage. An imported archive shows the account created. A failed archive shows the reason the import failed. An unreadable archive could not be inspected. Use --archive ID --inspect to inspect a tracked archive and save the result with the choices supplied. Use --archive ID --show to see the archive and its saved inspection. Use --archive ID --queue to queue an import with the choices supplied and link the job to the archive. Queuing requires the archive file to be present. It refuses a second import while one is queued or running or while the account created by an earlier import still exists. To run a tracked import directly, supply --archive ID with --file. Use --forget ID to remove an archive from the list while leaving its file in place. The import must be out of the queue and no longer running before you can forget it.Usage: urbestack-foreign-import --file /path/archive.tar.gz [--as NAME] [--owner RESELLER] [--paths rewrite|leave] [--default-mailbox LOCAL] [--skip-database NAME ...] [--job ID] urbestack-foreign-import --file /path/archive.tar.gz --inspect [--as NAME] [--owner RESELLER] [--default-mailbox LOCAL] [--skip-database NAME ...] urbestack-foreign-import --scan /root/import | --scan /path/archive.tar.gz [--owner RESELLER] urbestack-foreign-import --list [--owner RESELLER] urbestack-foreign-import --archive ID --show | --inspect [choices] | --queue [choices] | [--job ID] urbestack-foreign-import --forget ID [--owner RESELLER] Imports a hosting account into UrbeStack from a pkgacct archive or a full backup downloaded from the customer's panel on the source server. Use --file to specify the archive. The import keeps the original account name unless you specify --as NAME. It preserves a SHA-512 crypt login password. The web interface replaces the hash on the first successful login, while SFTP and FTP continue to accept the same password. Use --file with --inspect to read the archive metadata without unpacking the archive or creating the account. The report shows the account that would be created, missing PHP versions or services such as MariaDB and FTP, account name, domain and database conflicts, and anything the import would drop or leave behind. Blocking conflicts and missing requirements stop the import before it creates the account. If software must be installed first, the check gives the installation order. The import restores domains, subdomains and aliases with their document roots and PHP versions. It runs tar as the customer to unpack the home directory. By default, --paths rewrite replaces references to the old home path in .htaccess, .user.ini and php.ini. Use --paths leave to keep those references. The import lists any other files that refer to the old home path. It restores DNS zone records and updates records that point to the source server's IP address to point to this server's IP address. The import loads database dumps into MariaDB as supplied and restores database users and grants. Repeat --skip-database NAME up to 100 times to omit databases, for example when a name is already taken. The import skips each named dump and omits users associated only with skipped databases. The inspection, job log and import result identify the skipped databases. The import restores unexpired certificates that cover their domains. UrbeStack treats free certificates as its own and paid certificates as customer-provided. It also restores FTP accounts, SSH keys and cron jobs. If FTP is unavailable, it reports the skipped FTP accounts. The import restores mailboxes with their password hashes and quotas, forwarders, the default email address, autoresponders, DKIM keys under their original selectors, and webmail address books and identities. It applies the account's filters to every domain and restores each mailbox's own filters. Filter conversion uses heuristics and reports any filters it skips. It applies the account's hourly mail limit separately to each domain and routes mail for domains with external MX records to those servers. The account's mailbox at the top of mail/ becomes an ordinary mailbox under the main domain if the destination email address is free. It uses <name>@<main domain> by default. Use --default-mailbox LOCAL to set a different local part. The import logs each step, updates the job's progress percentage as steps finish and runs one rebuild at the end. It stops at the first failure, reports the steps that completed and leaves any partially imported account in place. Use --job ID to record progress under an existing job. A direct import creates its own job by default. Use --owner RESELLER to import under a reseller. The archive must belong to the reseller and be inside their home directory, and the new account must fit within the reseller's limits. Reseller paths are relative to the root of their home directory, and resellers see only their own archive entries. Use --scan with a directory to track its .tar.gz and .tgz archives in the Import section. The scan skips hidden files and symbolic links. A change in file size or modification time clears the saved inspection and keeps the import choices. Missing files are removed from the list, with entries kept for imported archives and imports that are queued or running. Use --scan with a file to add that archive wherever it is within the allowed paths. The import.dir setting sets the default import directory, which falls back to /root/import. For a reseller, the default is /import relative to their home directory. Use --list to see the tracked archives and their states. A new archive is awaiting inspection. A read archive shows the inspection counts and proposed account. An importing archive shows the job, current step and progress percentage. An imported archive shows the account created. A failed archive shows the reason the import failed. An unreadable archive could not be inspected. Use --archive ID --inspect to inspect a tracked archive and save the result with the choices supplied. Use --archive ID --show to see the archive and its saved inspection. Use --archive ID --queue to queue an import with the choices supplied and link the job to the archive. Queuing requires the archive file to be present. It refuses a second import while one is queued or running or while the account created by an earlier import still exists. To run a tracked import directly, supply --archive ID with --file. Use --forget ID to remove an archive from the list while leaving its file in place. The import must be out of the queue and no longer running before you can forget it.
Options
Find other commands that accept these optionsSame in the API
These operations run the command.GET/foreign/archivesList tracked hosting account archivesforeignPOST/foreign/archives/scanScan a directory for account archives or add a single archiveforeignGET/foreign/archives/{id}Get a tracked archive and its saved inspectionforeignDELETE/foreign/archives/{id}Remove an archive from the tracked listforeignPOST/foreign/archives/{id}/importQueue an import for a tracked archiveforeignPOST/foreign/archives/{id}/inspectInspect a tracked archive and save the reportforeignPOST/foreign/importQueue the import of a hosting account archiveforeignPOST/foreign/inspectPreview the import of a hosting account archiveforeign
urbestack-Generated from release 0.2.35 (current) · urbestack-foreign-import --help outputThis entry has been unchanged since it was first published in release 0.1.0 on 3 Oct 2026.
urbestack.com/docs/commands/urbestack-foreign-import/