one might use some padding around the frame part so that the p-clamp will be snug
this is a home made clamp, on the right
I use p-clamps to hold the rack on my road bike, but it's not ideal. they are strong enough but there are more elegant ways to do it
this is one of mine. it is not quite tight enough but there is minimal movement due to it's location, but the frame does show some wear