Enviado em 20/05/2021 - 19:15h
Eu primeiro exportei o xml de um site Wordpress e depois fiz um script para importar no outro site. Ocorre que esse script faz uma série de ações em sequencia. Talvez isso desgaste o servidor por estar o tempo todo trabalhando. Alguém sabe como pausar por um minuto após o processamento de cada xml fatiado? Isso ajuda o servidor ou não faz diferença? Segue os comandos que utilizei abaixo.
wp export --dir=/var/www/site.com.br/htdocs/backup --user=carlos --skip_comments --post_status=publish --filename_format={site}.{date}.{n}.xml --post_type=post --max_file_size=5 --start_date=2020-03-01 --end_date=2021-05-20 --allow-root
#!/bin/bash
wp import site.2021-05-20.000.xml --authors=create --allow-root
wp import site.2021-05-20.001.xml --authors=create --allow-root
wp import site.2021-05-20.002.xml --authors=create --allow-root
wp import site.2021-05-20.003.xml --authors=create --allow-root
wp import site.2021-05-20.004.xml --authors=create --allow-root
wp import site.2021-05-20.005.xml --authors=create --allow-root
wp import site.2021-05-20.006.xml --authors=create --allow-root
wp import site.2021-05-20.007.xml --authors=create --allow-root
wp import site.2021-05-20.008.xml --authors=create --allow-root
wp import site.2021-05-20.009.xml --authors=create --allow-root
wp import site.2021-05-20.010.xml --authors=create --allow-root
wp import site.2021-05-20.011.xml --authors=create --allow-root
wp import site.2021-05-20.012.xml --authors=create --allow-root
wp import site.2021-05-20.013.xml --authors=create --allow-root
wp import site.2021-05-20.014.xml --authors=create --allow-root
wp import site.2021-05-20.015.xml --authors=create --allow-root
wp import site.2021-05-20.016.xml --authors=create --allow-root
wp import site.2021-05-20.017.xml --authors=create --allow-root
wp import site.2021-05-20.018.xml --authors=create --allow-root
wp import site.2021-05-20.019.xml --authors=create --allow-root
wp import site.2021-05-20.020.xml --authors=create --allow-root
wp import site.2021-05-20.021.xml --authors=create --allow-root
wo clean --fastcgi
clear
wo clean --fastcgilimpa o cache se o servidor foi criado com o wordops (www.wordops.net)
Desktop Linux ganha fôlego enquanto distros refinam experiência e segurança
Wayland em alta, IA em debate e novos ventos para distros e devices
Qt 6.10 e Python 3.14 puxam o ritmo do software livre nesta quarta
Atualizações de Apps, Desktop e Kernel agitam o ecossistema Linux nesta terça-feira
Como mudar o nome de dispositivos Bluetooth via linha de comando
Adicionando o repositório backports no Debian 13 Trixie