With available information, we can only speculate. That said, the most likely cause may be resource exhaustion (i.e., insufficient available RAM or internal storage).
As a first step in avoiding recurrence, you would be wise to update your iPad to the most recent supported version of iPadOS - and in so doing, will also clear resources for smooth running of your iPad.
It is generally recommended that you maintain at least 4-6GB of free space at all times - as your iPad needs some temporary storage space to complete many tasks - such as task switching and performing system software updates.
A system software update requires sufficient space to be downloaded, unpacked and verified prior to installation - major version updates (such as updating from iPadOS 16.x to iPadOS 17/18) requiring considerably more space than an incremental point-update. After the update is successfully completed, temporary files are automatically deleted - returning free space.
If your internal storage is full, or is insufficient for the task that you need to perform, your only option is to better manage the storage that you have - and delete unused Apps or unneeded data.
These support pages should prove to be helpful:
About storage on your device and in iCloud – Apple Support
What's the difference between device storage and iCloud storage? – Apple Support
Manage your iCloud storage – Apple Support
How to check the storage on your iPhone, iPad and iPod touch – Apple Support
Clear Other storage on your iPhone or iPad - Apple Support
“Offloading” Apps can be a helpful method of creating temporary space for a software update.
https://9to5mac.com/2020/01/21/how-to-offload-apps-in-ios-to-save-space-without-deleting-their-data/
Additional information about creating sufficient space for installation of a software update can be found here:
If you need more space for an update on your iPhone, iPad, or iPod touch - Apple Support
External storage options can often help with managing limited internal storage. Depending upon your iPad model, the iPad will either have a Lightning or USB-C port - and may therefore require either an Adapter or USB hub to connect the USB Storage device. If your iPad has a Lightning port, you’ll need an Apple Lightning to USB3 Camera Adapter:
- Lightning to USB 3 Camera Adapter
https://store.apple.com/xc/product/MK0W2ZM/A
Updating your iPad using a Windows PC (with iTunes for Windows or Apple Devices App installed) or Mac computer (with iTunes or Finder - as appropriate for the installed version of macOS) can reduce the amount of iPad free-space necessary to perform the update - as the initial download, unpacking and verification is performed on the computer prior to installation of the unpacked update. However, even this method is not possible if your iPad has too little free space.