The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 2,909 other followers

Archive for May 5th, 2021

ESXi: where are my log files actually stored? Actually, most of them are in `/scratch/log` which points to a hidden `.locker` directory in a datastore.

Posted by jpluimers on 2021/05/05

A summary of the full gist at [Wayback/Archive.is] ESXi-where-are-my-log-files-stored.txt:

# ls -al / /var/ /var/log/ /var/run/ /scratch/ /scratch/log/ | grep "/\|log\|-\>"
/:
...
lrwxrwxrwx    1 root     root            57 Apr  4 18:16 scratch -> /vmfs/volumes/5ce2d440-72311161-75c5-0025907d9d5c/.locker
...
/scratch/:
drwxr-xr-x    1 root     root        106496 Apr 10 08:40 log
/scratch/log/:
-rw-------    1 root     root           411 Apr  4 18:20 Xorg.log
...
-rw-------    1 root     root         78835 Apr  4 10:30 syslog.0.gz
-rw-------    1 root     root         61136 Mar 18 15:05 syslog.1.gz
-rw-------    1 root     root         60589 Feb 24 00:30 syslog.2.gz
-rw-------    1 root     root         60373 Feb  1 08:01 syslog.3.gz
-rw-------    1 root     root         60203 Jan  9 15:50 syslog.4.gz
-rw-------    1 root     root         59889 Dec 17 23:20 syslog.5.gz
-rw-------    1 root     root         60398 Nov 25 06:50 syslog.6.gz
-rw-------    1 root     root         60563 Nov  2 14:25 syslog.7.gz
-rw-------    1 root     root        531794 Apr 10 09:35 syslog.log
...
-rw-------    1 root     root        157255 Apr  4 18:17 vvold.log
/var/:
...
drwxr-xr-x    1 root     root           512 Apr  5 19:19 log
...
/var/log/:
-rw-r--r--    1 root     root           416 Apr  4 18:16 .vmsyslogd.err
...
-rw-r--r--    1 root     root         38069 Apr  4 18:20 configRP.log
-rw-r--r--    1 root     root             0 Apr  4 18:16 cryptoloader.log
...
-rw-r--r--    1 root     root            87 Apr  5 21:57 esxcli.log
...
-rw-------    1 root     root          3350 Apr  4 18:16 init.log
-rw-r--r--    1 root     root           966 Apr  4 18:16 iofilter-init.log
...
-rw-r--r--    1 root     root         21769 Apr  4 18:16 jumpstart-esxcli-stdout.log
-rw-r--r--    1 root     root         18857 Apr  4 18:16 jumpstart-native-stdout.log
-rw-r--r--    1 root     root         10837 Apr  4 18:16 jumpstart-stdout.log
-rw-r--r--    1 root     root             0 Apr  4 18:16 kickstart.log
...
-rw-------    1 root     root         10916 Apr  4 18:16 sysboot.log
...
-rw-------    1 root     root            64 Apr 10 09:13 tallylog
...
/var/run/:
lrwxrwxrwx    1 root     root            12 Apr  4 18:16 log -> /scratch/log
  • Almost all log files (most from /var/log and all from /var/run/log) are actually persistently stored in /scratch/log and survive reboots. Just a few are non-persistent.
  • /var/log/syslog is being archived as .gz files (compressed by gzip).
  • syslog is special: the location can be configured, and even be external: [Wayback] Configuring syslog on ESXi (2003322)

    VMware vSphere ESXi 5.0 and higher hosts run a Syslog service (vmsyslogd) that provides a standard mechanism for logging messages from the VMkernel and other system components. By default in ESXi, these logs are placed on a local scratch volume or a ramdisk. To preserve the logs further, ESXi can be configured to place these logs to an alternate storage location on disk and to send the logs across the network to a Syslog server.

  • A summary of some of the above log files is at [Wayback] ESXi Log File Locations

–jeroen

Posted in *nix, *nix-tools, ash/dash, ash/dash development, BusyBox, Development, ESXi6, ESXi6.5, ESXi6.7, ESXi7, gzip, Power User, Scripting, Software Development, Virtualization, VMware, VMware ESXi | Leave a Comment »

Running ArchiveTeam Warrior version 3.2 on ESXi

Posted by jpluimers on 2021/05/05

A while ago I wrote about Helping the WayBack ArchiveTeam team: running their Warrior virtual appliance on ESXi.

Since it was scheduled before my cancer treatment started and got posted when still recovering from it, I missed that version 3.2 of the [Wayback] ArchiveTeam Warrior appliance appeared in the [Wayback] Releases · ArchiveTeam/Ubuntu-Warrior at [Wayback] Release v3.2 · ArchiveTeam/Ubuntu-Warrior. You can download it form these places:

These two sites have not yet been updated, so they contain the older versions:

The source code now has been moved three times:

Read the rest of this entry »

Posted in *nix, *nix-tools, ArchiveTeamWarrior, Cloud, Containers, diff, Docker, ESXi5, ESXi5.1, ESXi5.5, ESXi6, ESXi6.5, ESXi6.7, ESXi7, Infrastructure, Internet, InternetArchive, Kubernetes (k8n), KVM Kernel-based Virtual Machine, patch, Power User, VirtualBox, Virtualization, VMware, VMware ESXi, VMware Workstation, WayBack machine | Leave a Comment »

Delphi 10.2 Tokyo introduced a “with” warning: for most “with” statements, W1048 is raised ([RSP-17326] with statements generate W1048 unsafe typecast warning – Embarcadero Technologies)

Posted by jpluimers on 2021/05/05

A cool feature introduced in Delphi 10.2 Tokyo: often [RSP-17326] with statements generate W1048 unsafe typecast warning – Embarcadero Technologies.

Only 2 upvotes, so I assume the “anti with camp” people are finally winning (:

Notes:

Quoted from the bug-report (as they cannot be archived in the wayback machine)

  1. RAD Studio
  2. RSP-17326

with statements generate W1048 unsafe typecast warning

Details

  • Type:Bug Bug
  • Status:Reported Reported
  • Priority:Major Major
  • Resolution:Unresolved
  • Affects Version/s:10.2 Tokyo
  • Fix Version/s:None
  • Component/s:Delphi Compiler
  • Labels: None
  • Build No: 25.0.25948.9960
  • Platform: All
  • Language Version: English
  • Edition: Enterprise
  • InternalID: RS-82298
  • InternalStatus: Validation

Description

All with statements generate this warning. I am on board with the theory that all with statements are inherently somewhat unsafe, but with 1.5 million lines of legacy code (and over 500 new warnings), I would significantly prefer to have a separate warning for with statements.
As it happens I would like to go through and do this work, especially if we can have refactoring to restore non-with code – see RSP-13978. BUT, Godzilla is generating new extra warnings (including unsafe typecasts) in this legacy code and I would prefer to be able to attack these first and attend to with statements later.

Activity

Comments

Jira-Quality Sync Service added a comment – 

Jason Sprenger requested more info in order to validate the issue and commented: Not any code involving “with” statements produces an unsafe typecast warning.

For instance,

program RS82298;

{$APPTYPE CONSOLE}

uses
  System.SysUtils;

procedure Use(var X);
begin<
end;

type
  TMyClass = class
    FValue: Integer;
    property Value: Integer read FValue write FValue;
  end;

procedure RunRS82298;
var
  MyClass: TMyClass;
begin
  MyClass := TMyClass.Create;
  with MyClass do
    begin
      Value := 42;
    end;
  with MyClass do
    WriteLn('MyClass.Value=', MyClass.Value);

  Use(MyClass);
end;

begin
  try
    RunRS82298
  except
    on E: Exception do
      begin
        WriteLn('FAIL - Unexpected Exception');
        WriteLn('  ClassName=', E.ClassName);
        WriteLn('    Message=', E.Message);
      end;
  end;
end.

What sort of source involving “with” statements is generating these warnings for you?

With this information our development team can consider addressing your particular circumstance.

Stuart Seath [X] (Inactive) added a comment – 

Try this (obviously a simple made-up example), and you do need to enable W1048 first in the project options:

program Project18;

{$APPTYPE CONSOLE}

{$R *.res}

uses
  System.SysUtils;

type
  TAnother = class
  private
    FAmbiguous : Boolean;
  public
    property Ambiguous : Boolean read FAmbiguous write FAmbiguous;
  end;

  TFirst = class
  private
    FAnother : TAnother;
  public
    procedure Doit;
  end;

var
  First : TFirst;

{ TFirst }

procedure TFirst.Doit;
begin
  FAnother := TAnother.Create;
  with FAnother do // WARNING
  begin
    Ambiguous := true;
  end;
end;

var
  XAnother : TAnother;

begin
  try
    XAnother := TAnother.Create;
    with XAnother do // NO WARNING HERE
    begin
      Ambiguous := true;
    end;

  except
    on E: Exception do
  Writeln(E.ClassName, ': ', E.Message);
end;
end.

–jeroen

Posted in Delphi, Delphi 10.2 Tokyo (Godzilla), Development, Software Development | 1 Comment »

 
%d bloggers like this: