Comment trouver l'emplacement du fichier journal d'alerte dans Oracle

cumulus

In newer versions of Oracle Database it is not obvious where is the location of the alert file to investigate any potential issues.

If you want to know how to check alert log errors in Oracle, then keep reading.

You have a couple of ways to know where your Oracle alert file is located.

1. If the Oracle database is opened

You can use this query after connecting with: sqlplus / as sysdba

select * 
from v$diag_info 
where NAME = 'Diag Trace';

2. If the Oracle database is not opened

You can use adrci from the command line

# adrci

ADR base = "/u01/app/oracle"
adrci> show homes
ADR Homes:
diag/rdbms/yp001p/YP001P1
diag/rdbms/azamoa/azamoa1
diag/clients/user_oracle/host_2133002082_110
diag/tnslsnr/xm1iddb21/listener_dg
adrci>

You can see there are several homes.

If you want to check the alert file for database YP001P1 then you should use the ADR base followed by the ADR home (from the output above) and then add the trace folder at the end

cd /u01/app/oracle/diag/rdbms/yp001p/YP001P1/trace

Once in that folder you can check the alert file

ls -lrt alert*

Vérifier tous les journaux de l'hôte virtuel Apache sur Ubuntu

tissu avec motif artistique

J'ai parfois besoin de vérifier tous mes hôtes virtuels sur mon serveur Apache.

La meilleure façon de le faire est d'utiliser la commande cat comme suit

/var/log/apache2# cat *.access.log

Si je veux continuer à observer le journal, j'utilise la commande tail comme suit

/var/log/apache2# tail -f *.access.log

Mais si je veux vérifier quelque chose de plus spécifique, je peux aussi utiliser un grep.

/var/log/apache2# cat *.access.log | grep root

C'est un moyen rapide de vérifier mes journaux sans avoir à les vérifier un par un.