Publicamos atualizações frequentes em nossa documentação, e a tradução desta página ainda pode estar em andamento. Para obter as informações mais recentes, acesse a documentação em inglês. Se houver problemas com a tradução desta página, entre em contato conosco.
Versão do artigo: Enterprise Server 2.19

Enabling and scheduling maintenance mode

Some standard maintenance procedures, such as upgrading sua instância do GitHub Enterprise Server or restoring backups, require the instance to be taken offline for normal use.

Neste artigo

About maintenance mode

Some types of operations require that you take sua instância do GitHub Enterprise Server offline and put it into maintenance mode:

  • Upgrading to a new version of GitHub Enterprise Server
  • Increasing CPU, memory, or storage resources allocated to the virtual machine
  • Migrating data from one virtual machine to another
  • Restoring data from a GitHub Enterprise Server Backup Utilities snapshot
  • Troubleshooting certain types of critical application issues

We recommend that you schedule a maintenance window for at least 30 minutes in the future to give users time to prepare. When a maintenance window is scheduled, all users will see a banner when accessing the site.

End user banner about scheduled maintenance

When the instance is in maintenance mode, all normal HTTP and Git access is refused. Git fetch, clone, and push operations are also rejected with an error message indicating that the site is temporarily unavailable. Visiting the site in a browser results in a maintenance page.

The maintenance mode splash screen

Enabling maintenance mode immediately or scheduling a maintenance window for a later time

  1. In the upper-right corner of any page, click .
    Ícone de foguete para acessar as configurações de administrador do site
  2. In the left sidebar, click Console de gerenciamento.
    Console de gerenciamento tab in the left sidebar
  3. At the top of the Console de gerenciamento, click Maintenance.
    Maintenance tab
  4. Under "Enable and schedule", decide whether to enable maintenance mode immediately or to schedule a maintenance window for a future time.
    • To enable maintenance mode immediately, use the drop-down menu and click now.
      Drop-down menu with the option to enable maintenance mode now selected
    • To schedule a maintenance window for a future time, use the drop-down menu and click a start time.
      Drop-down menu with the option to schedule a maintenance window in two hours selected
  5. Select Enable maintenance mode.
    Checkbox for enabling or scheduling maintenance mode
  6. Under the left sidebar, click Save settings.
    Botão Save settings (Salvar configurações)

Scheduling maintenance mode with API do GitHub Enterprise Server

You can schedule maintenance for different times or dates with API do GitHub Enterprise Server. For more information, see "Management Console."

Enabling or disabling maintenance mode for all nodes in a cluster

With the ghe-cluster-maintenance utility, you can set or unset maintenance mode for every node in a cluster.

$ ghe-cluster-maintenance -h
# Shows options
$ ghe-cluster-maintenance -q
# Queries the current mode
$ ghe-cluster-maintenance -s
# Sets maintenance mode
$ ghe-cluster-maintenance -u
# Unsets maintenance mode

Pergunte a uma pessoa

Não consegue encontrar o que procura?

Entrar em contato