I have an existing installation of discourse however i did not upgrade last few releases. Its hosted by digital ocean. This mornng when i tried to upgrade through manual, i am getting the following error. Please can you guide as what step i should take to upgrade this.
use either du -sh * and drill down into the large directories or ncdu if you have that package available, and try to figure out where exactly your space has gone
if it is user content you will probably have to increase diskspace on your server, but a common problem on servers that run docker for a while is that the default json logging engine never rotates the logs
[root@discocent discourse]# cd /var/lib/docker/containers/
[root@discocent containers]# du -sh *
5.1M 86981cd18ab1d8e95e502bf08a1fdc949030cddc29079b53a8e17b2c6a98ba6f
36K cecf3b8565bce6156c61f61b27af425d0f956b8ce439f2519300ebfdc7bb4cf9
[root@discocent containers]# cd 86981cd18ab1d8e95e502bf08a1fdc949030cddc29079b53a8e17b2c6a98ba6f/
[root@discocent 86981cd18ab1d8e95e502bf08a1fdc949030cddc29079b53a8e17b2c6a98ba6f]# ls -lh
total 5.1M
-rw-r-----. 1 root root 5.0M Jan 16 10:07 86981cd18ab1d8e95e502bf08a1fdc949030cddc29079b53a8e17b2c6a98ba6f-json.log
that’s 5M of log for my idle test instance after a couple days, an active server will be larger. if you run other containers they might be logging even more.
Many thanks. this is much appreciated. I have run the commands and i can see the following statistics. Would you mind to advise, how does this look like as I am unable to interpret I am afraid. Thanks in advance.
ok, that’s not your problem then. Only one container and only 0.5MB of logs.
if you run du -sh * again in the / top directory maybe you will get a better picture of where the space has gone. I highly recommend ncdu to make it easier ( NCurses Disk Usage )
docker image prune -a usually frees up a lot of space for me, you might have to docker rm app to delete your old Discourse app container first. If you have lots of forum backups maybe you could download them to your local machine to free up some additional space.
another thing you should check is docker ps -a to see if you have any unexpected containers. Sometimes a failed rebuild will leave a dangling container that you have to remove manually.
[root@discocent /]# docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
86981cd18ab1 da251a932851 "/bin/bash -c 'cp -r…" 4 days ago Exited (0) 4 days ago festive_margulis
[root@discocent /]# docker rm festive_margulis
festive_margulis
[root@discocent /]# docker image prune -a
WARNING! This will remove all images without at least one container associated to them.
Are you sure you want to continue? [y/N] y
Deleted Images:
deleted: sha256:da251a9328516f691f0fc3bcdd685e218fa075ae744766996a25b7fe0008b4fc
deleted: sha256:3adfc688f9c999f5f08caae668a722c273311c3f84da33161bf23184218fa74b
deleted: sha256:ea31cd77735ab3d86f3d8903425d4157320b7047a07da4555a4752614c6e5265
deleted: sha256:b375a11cf89e3f124f9151688c2952ef8ca45f5ab5f2bd0751ea3f617708df87
deleted: sha256:cce92fda689ab9033f0b8db214bc63edd1ae3e05831a0f3a9418976d7dc7ccdd
deleted: sha256:d22094bbd65447c59a42c580eaa3a44cee9cd855f00905f59409be21bcefc745
deleted: sha256:b8976847450013f3eb5e9a81a5778f73ed7bef67e6393049712ef17102b4b7b7
deleted: sha256:b8c891f0ffec910a12757d733b178e3f62d81dbbde2b31d3b754071c416108ed
Total reclaimed space: 2.33GB
Hola @pfaffman Una pregunta rápida relacionada con esto. Me encontré con el mismo problema, así que ejecuté du -sh *. Ninguno de los archivos supera 1 MB.
Así que no lo eliminé.
pero intenté docker image “prune -a”, espacio recuperado: 0B.
¿Hay algo más que deba hacer?
Mi problema está relacionado con la última actualización que hice y que provocó el cierre de la aplicación.
¿Has revisado /var/discourse/shared/standalone/backups/default? Ese es el culpable más probable.
Estoy trabajando en un nuevo producto en https://www.pfaffmanager.com/. Si inicias sesión allí, haz clic en el botón lista de servidores en la parte superior y luego en el botón ¡Gratis! Gestionar servidor existente y luego configúralo para tu servidor como (espero) sugiere, lo resolveré por ti.
Gracias, sí, revisé las copias de seguridad. Total 5 archivos * 16M. Eso es poco, ¿verdad?
También ejecuté esto
==================== INFORMACIÓN DE MEMORIA ====================
RAM (MB): 1002
total used free shared buff/cache available
Mem: 978 692 68 33 216 110
Swap: 2047 242 1805
==================== COMPROBACIÓN DE ESPACIO EN DISCO ====================
---------- Espacio en disco del SO ----------
Filesystem Size Used Avail Use% Mounted on
/dev/xvda1 12G 11G 848M 93% /
---------- Espacio en disco del contenedor ----------
Filesystem Size Used Avail Use% Mounted on
overlay 12G 11G 848M 93% /
/dev/xvda1 12G 11G 848M 93% /shared
/dev/xvda1 12G 11G 848M 93% /var/log
Estoy probando tu sugerencia ahora el nuevo producto.
Ok, entendido. Hace unos minutos, aumenté el volumen a 30, quizás todavía se está optimizando
Por cierto, estoy confundido con la interfaz de usuario de tu producto, pero también sentí un interés repentino en cómo vas a depurar desde allí. jajaja. Te enviaré un mensaje privado para evitar romper las reglas aquí.