Skip to content

Failed to access file /cascache/cascache/ #151

Open

Description

@FK7

Hi Team,

I attempted to utilize the swat package to push a pandas dataframe as a Sas table to a Sas server, but I encountered an error message that states "Failed to access cache file." Below is the code that I am executing for your reference. I would highly appreciate your assistance.

Code:

Verify file existence at a designated path

if not os.path.exists(castable_path):
raise ValueError("Unable to locate CASTable at the specified path.")

Transfer CASTable to SAS server

try:
conn.loadactionset("table")
conn.upload(castable_path, casout=dict(name="mytable_1", replace=True, caslib='CASUSER(sasboot)'))
print("CASTable successfully uploaded!")
except swat.CASActionError as e:
print(f"An error occurred while uploading CASTable: {e}")

Please note that I received the following output while running the code:

NOTE: Added action set 'table'.
CASTable uploaded successfully!

ERROR: Failed to access file /cascache/cascache/_f_1e7ad78a_7f7b9bcc1b68.sashdat.
ERROR: The action stopped due to errors.

Activity

  1. bkemper24 commented on Mar 2, 2023

    @bkemper24
    Contributor

    The upload action is failing on the CAS server side. Do you have access to the CAS controller log file at the time that the upload was being done ? Are there any errors reported in the CAS controller log ? If you are able to turn up the log levels in the CAS server, TRACE level of the App.cas.tables logger would be helpful.

    Also, how big is the file you are trying to upload ?

  2. FK7 commented on Mar 5, 2023

    @FK7
    Author

    Thank you for your message @bkemper24 . I will request our SAS admin to check the controller logs and I will follow up with you once I receive more information.

    Furthermore, I am not attempting to upload a file. Instead, I have created a sample dataframe with dummy records, which you can review in the code that I provided.

  3. bkemper24 commented on Mar 6, 2023

    @bkemper24
    Contributor

    Also, do you know if the CAS_DISK_CACHE was kustomized ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions